Class GraphQlHttpHandler.Builder
java.lang.Object
org.springframework.graphql.server.webflux.GraphQlHttpHandler.Builder
- Enclosing class:
GraphQlHttpHandler
Builder for
GraphQlHttpHandler.- Since:
- 2.1.0
- Author:
- Rossen Stoyanchev, Brian Clozel
-
Method Summary
Modifier and TypeMethodDescriptionbuild()Build theGraphQlHttpHandler.codecConfigurer(CodecConfigurer codecConfigurer) Set the codec configurer to use for JSON encoding and decoding.httpMethods(HttpMethod... httpMethods) Set the HTTP methods that the handler should support.
-
Method Details
-
codecConfigurer
Set the codec configurer to use for JSON encoding and decoding.If not set, the handler will use the one configured for web use.
- Parameters:
codecConfigurer- the codec configurer to use
-
httpMethods
Set the HTTP methods that the handler should support.By default, only
HttpMethod.POSTis supported. EnablingHttpMethod.GETmeans that queries and their parameters are exposed through the request URL; consider the security implications, for example URLs being logged or cached, before enabling it.- Parameters:
httpMethods- the HTTP methods to support
-
build
Build theGraphQlHttpHandler.
-