Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data fetcher instance optimization in GQL API #743

Open
2 tasks done
lukashornych opened this issue Nov 12, 2024 · 1 comment
Open
2 tasks done

Data fetcher instance optimization in GQL API #743

lukashornych opened this issue Nov 12, 2024 · 1 comment
Assignees
Labels
performance Performance problem.

Comments

@lukashornych
Copy link
Collaborator

lukashornych commented Nov 12, 2024

Lots of non-parameterized data fetcher are instantiated for each usage. This is not very optimal for memory usage. All usages of such data fetcher should share a single instance of that data fetcher.

Other parameterized data fetchers could be maybe optimized to a single shared instance as well with help of GQL local context passed through data fetchers. We should look into that.

  • optimize non-parameterized data fetcher usage
  • look into optimizing parameterized data fetcher usage
@lukashornych
Copy link
Collaborator Author

Optimized non-parameterized data fetcher usages are implemented in 677-entity-archivation.

Regarding the parameterized data fetchers, after some examination, there doesn't seem to be an easy way of sharing instances, because in such case we don't have any other way of passing parameters from schema to a data fetcher. Trying to pass the parameters into GQL local context is usually too late.

@lukashornych lukashornych added the performance Performance problem. label Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Performance problem.
Projects
None yet
Development

No branches or pull requests

1 participant