spring-data-rest icon indicating copy to clipboard operation
spring-data-rest copied to clipboard

Spring Data REST force using of jackson serialization

Open xanscale opened this issue 1 year ago • 2 comments

there is no way to change json serialization, like kotlinx-serialization or gson or others.

inside RepositoryRestMvcConfiguration jackson seams hardcoded and no way to change.

https://docs.spring.io/spring-framework/reference/languages/kotlin/web.html#kotlin-multiplatform-serialization

xanscale avatar Dec 10 '24 10:12 xanscale

Exactly. Spring Data REST is built on top of Jackson, and we use Jackson in various areas. It would require a significant rework to support other serialization mechanisms.

mp911de avatar Dec 10 '24 14:12 mp911de

It's a very unexpected answer :) in my mind data REST is on top of RestController, something like autogenerated standard RestController

at least it should be specified in the documentation

I'm making rest api with data REST and kotlin, but Jackson and Kotlin are not good friends

xanscale avatar Dec 10 '24 15:12 xanscale