| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…reate `DataFetcherFactoryEnvironment` objects for simple property fetchers
| public DataFetcher<Object> get(GraphQLFieldDefinition fieldDefinition) { | ||
| return SINGLETON_FETCHER; | ||
| } | ||
| }; |
There was a problem hiding this comment.
because I didnt override the default public DataFetcher<Object> get(GraphQLFieldDefinition fieldDefinition) then it returned null and hence it went to the older more heavy weight object and a DataFetcherFactoryEnvironment needed to be allocated.
This now means that no DataFetcherFactoryEnvironment objects are allocated for property fetchers
Sorry, something went wrong.
There was a problem hiding this comment.
I cant unit test this - its not observable - but profiling shows it to be working!
Sorry, something went wrong.
There was a problem hiding this comment.
Nice you could verify via profiling
Sorry, something went wrong.
Test Results 312 files 312 suites 53s ⏱️ Results for commit ade6100. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
This was always the intention here when we created #3754 to have a singleton property fetcher instance
However we didnt do the factory right and hence DataFetcherFactoryEnvironment are created when they dont need to be
This fixes on of the items found in #3939
Namely why was "graphql.schema.DataFetcherFactoryEnvironment" being 2% of objects allocated
This fixes that
re : #3941