Enhancements
Configure servlet async mode
Added property for configuring async servlet mode:
graphql:
servlet:
asyncModeEnabled: true
Option for disabling introspection query
Graphql-java provides a feature to disable the introspection query: https://graphql-java.readthedocs.io/en/latest/execution.html?highlight=introspection#limiting-field-visibility. They do warn that it puts your server in contravention of the GraphQL specification and expectations of most clients so use this with caution.
If you want you can disable the introspection query now by setting the following property:
graphql:
tools:
introspectionEnabled: false
Bugs
Spring Object Mapper overridden by GraphQL
The default Spring Object Mapper provided by Spring through JacksonAutoConfiguration
was overridden by the one provided by GraphQL
.
GraphiQL stylesheet and script failed loading on custom path
When GraphiQL is run on a custom path it would fail to load its stylesheet and javascript because the base path wasn't determined correctly.
Voyager static resources not served if app context is not root
When the application has a context different than root Voyager fails to start because its static resources are not found 404. This is because the HTML is configured as they were always in the root directory which is not the case.
GraphQLTest or SpringBootTest not working
In some configurations the @GraphQLTest
wouldn't load properly. The @SpringBootTest
would only work if it was configured to run with a webEnvironment
, because otherwise it would fail due to missing ServerContainer
. Both scenarios have been fixed in this release.