leangen / graphql-spqr

Build a GraphQL service in seconds
Apache License 2.0
1.09k stars 179 forks source link

Rewrite scalar coercion to stop depending on deprecated methods #451

Open kaqqao opened 1 year ago

kaqqao commented 1 year ago

The entire scalar coercion implementation has to change, because:

a) graphql-java deprecated the methods SPQR is currently using (e.g. parseValue(Object)) and the new signatures cause problems in ValueMapper, which also operates outside of query execution and thus has no access to GraphQLContext

b) SPQR can't reliably tell a Java type is mapped as scalar when deserializing the inputs, so flimsy workarounds like this are needed