This is a follow-up to #1506, which introduced the mechanism for restricting which GraphQL operation types a request may execute.
This issue is about using that mechanism in the existing transports:
GraphQlHttpHandler (WebMvc/WebFlux) only supports query/mutation.
GraphQlSseHandler (WebMvc/WebFlux) only supports subscription.
This is a prerequisite for #1450 and #1505, which will further restrict operations based on HTTP method (GET/QUERY must exclude mutations).
This changes existing behavior; a subscription sent to GraphQlHttpHandler over POST currently fails when the transport tries to serialize a Publisher as JSON; it will instead be rejected up front with a proper GraphQL error.
This is a follow-up to #1506, which introduced the mechanism for restricting which GraphQL operation types a request may execute.
This issue is about using that mechanism in the existing transports:
GraphQlHttpHandler(WebMvc/WebFlux) only supports query/mutation.GraphQlSseHandler(WebMvc/WebFlux) only supports subscription.This is a prerequisite for #1450 and #1505, which will further restrict operations based on HTTP method (GET/QUERY must exclude mutations).
This changes existing behavior; a subscription sent to
GraphQlHttpHandlerover POST currently fails when the transport tries to serialize aPublisheras JSON; it will instead be rejected up front with a proper GraphQL error.