Skip to content

Add DataFetchingEnvironment parameter to main query resolver #61

@joffrey-bion

Description

@joffrey-bion

Is your feature request related to a problem? Please describe.
When using GraphQL Java Tools, the main Query resolver, like other resolvers, can take an optional DataFetchingEnvironment parameter.
It is currently generated in all resolvers interfaces, but not for the root resolvers like Query.

Describe the solution you'd like
It'd be nice to provide this DataFetchingEnvironment argument to the query resolver's methods.
If we need backwards compatibility, we could use a config parameter to add or not the DataFetchingEnvironment argument in the generated interfaces.

Describe alternatives you've considered
There is no other way currently than to stop implementing the Query interface, which is a pain because changes to the schema don't make the compilation fail.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions