Skip to content

How to use LegacyCoercingInputInterceptor in v22 #3594

Answered by bbakerman
piotrblasiak asked this question in Q&A
Discussion options

You must be logged in to vote

The code that uses this callback is still in place in V22 - but it being on by default has changed

the value conversion code does

InputInterceptor inputInterceptor = graphqlContext.get(InputInterceptor.class);

So you need to place a LegacyCoercingInputInterceptor into the requests graphql.GraphQLContext under the key graphql.execution.values.InputInterceptor class.

It will then run that code during value conversion

The reason it was removed in the V22 breaking change version is that we wanted to move to a more spec compliant value conversion and the breaking change version was the time to do it. We knew it may hurt some people relying on old value shapes so we pre built this conversion c…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@piotrblasiak
Comment options

Answer selected by piotrblasiak
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants