Netflix / dgs-framework

GraphQL for Java with Spring Boot made easy.
https://netflix.github.io/dgs
Apache License 2.0
3.03k stars 286 forks source link

Register jdk8 module in DgsSSESubscriptionHandler #1950

Closed kailyak closed 2 days ago

kailyak commented 6 days ago

Pull Request type

Changes in this PR

Describe the new behavior from this PR, and why it's needed Internally the use case arose for needing to serialize java 8 Optionals in SSE subscription calls. Since the object mapper in DgsSSESubscriptionHandler is not configured for the Jdk8 module an error was thrown when that type was part of the payload here.

Testing done

Tested on app which had the serialization error.