Skip to content

[Question] How to clear the cache of a loader from a service? #22

@GauthierPLM

Description

@GauthierPLM

I'd like to purge the cache of my loader from my service when the service update / delete data in the DB.
With the DI, I can easily get them in resolvers but I believe the services are the best place to hold such logic. However, I am not sure how to properly retrieve a loader in my service.

I checked how the @loader() decorator works and noticed it uses an internal store not available outside the DataloaderModule, so I understand I can't rely on it.

Would you be able to help? :)

Metadata

Metadata

Labels

questionFurther information is requested

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions