Gunnar Morling @gunnarmorling.dev 路 May 18

"Towards a JSON API for the JDK" New proposal on the core-libs-dev list for adding a basic JSON API to #Java. That would be a more than welcome addition, in particular considering the envisioned usage once member patterns will be available. Make it So 馃ぉ! mail.openjdk.org/pipermail/co...

42 likes 4 replies

?

Replies

Cl茅ment Levallois 路 May 18

I had asked for it like 5 years ago on Twitter and it was dismissed by pros as a peripheral endeavor. I feel vindicated 馃榿 Btw is it possible to "just" take and adapt the Jakarta json processing and binding libs? jakarta.ee/specificatio...

The Unknown Developer 路 May 19

Why is it needed to reinvent the wheel and not just take something like Jackson and include it?

S

@streamlined2.bsky.social 路 May 19

Looks ghastly and very cumbersome. Multiple use of instanceof usually indicates OOP design flaws. Does JSON actually deserves separate type hierarchy? Why not map directly into native Java types? Why not throw exception if parse fails?

Babak Farhang 路 May 19

Expressing happy-path behavior is easy, imo; handling unhappy code paths w/ the least amount of boilerplate is the challenge.. e.g. when that "age" property turns out to be a string when it shoulda been a number, I want to make a useful error message (by way of exceptions or whatever) that says so