Split CBOR encoder to support Jackson 2 and 3#134
Conversation
CodeDrivenMitch
left a comment
There was a problem hiding this comment.
We need to downgrade the Kotlin version, and update the copyright headers. Hence not approving yet.
| <dependency> | ||
| <groupId>com.fasterxml.jackson.dataformat</groupId> | ||
| <artifactId>jackson-dataformat-cbor</artifactId> | ||
| <scope>provided</scope> |
There was a problem hiding this comment.
I am wondering why there is a differnece between cbor and kotlin here. Why do we include kotlin transitively, but not cbor?
As we would like to default to Jackson 3 (but first check whether Jackson 2 is on the classpath instead), I think it makes sense to make both provided and optional. Wdyt?
There was a problem hiding this comment.
Good question. I’m also not sure why it was decided this way in the main branch, perhaps to avoid requiring users to install a Kotlin dependency when their project is purely written in Java.
On the other hand, Jackson 2 is no longer the default approach, so it’s probably acceptable if users need to take this extra step and add the dependency themselves.
I’ve now adopted your proposal and made the dependency provided and optional.
|




Refactor the CBOR encoder to provide separate support for Jackson 2 and Jackson 3, with the goal of supporting Spring Boot 4.