12

I just found out that Jackson does not implement JSR-353 and we already designed the module.. so i am in a desperate hurry to find a replacement of this API to begin working ! :D

I searched an API that implements the standard but could not find any interesting result because we plan to code with the standard and force the system to use a particular implementation (the API i am desperately searching for)

Paul Sweatte
  • 24,148
  • 7
  • 127
  • 265
maher.belkh
  • 473
  • 2
  • 7
  • 21
  • I know that Jackson, Gson, etc.. does exist and are the better ones but the implementation thing is problematic so my question does simply mean "do you know about an api that implements the standard json jsr-353" so i thnik that it's not a recommandation or something like that no ? – maher.belkh Jan 16 '15 at 13:29
  • 7
    some users on Stack Overflow are becoming "purists". This was a really interesting question as it is for me also hard to find a list of the apis that implement JSR353. When the rules start working against the users' interests, you have to start thinking about changing some... – andrei.serea Oct 30 '17 at 11:47
  • 1
    Note that [JSR-374](https://jcp.org/en/jsr/detail?id=374), as an update to JSR-353, has been released and included in Java EE 8. – Franklin Yu Dec 20 '17 at 04:28
  • 1
    On the Software Recommendations Stack Exchange, see: [*Actual implementation of JSR-353 (JSON)?*](https://softwarerecs.stackexchange.com/questions/47697/actual-implementation-of-jsr-353-json) – Basil Bourque May 28 '18 at 22:30

2 Answers2

15

Reference implementation

Here is the reference implementation for JSR 353 and its successor JSR 374: JavaTM API for JSON Processing 1.1 in Java EE 8:

https://javaee.github.io/jsonp/

Binding

Related is JSR 367: JavaTM API for JSON Binding (JSON-B) and its reference implementation, Eclipse Yasson.

Basil Bourque
  • 303,325
  • 100
  • 852
  • 1,154
vanje
  • 10,180
  • 2
  • 31
  • 47
  • I think it is not a finalized project no ? clicking on "Documentation" directs me to a "Oracle : We're sorry, the page you requested was not found". – maher.belkh Jan 16 '15 at 13:24
  • @maher.belkh The URL is wrong. I don't know if it changed or if they got it wrong, but the documentation is [here](http://docs.oracle.com/javaee/7/tutorial/jsonp.htm). – dcsohl Jan 16 '15 at 14:56
  • Here are the API docs: https://json-processing-spec.java.net/nonav/releases/1.0/fcs/javadocs/index.html – vanje Jan 16 '15 at 16:26
  • 1
    They fixed the URL on site since then. – Anton Aug 18 '15 at 10:57
5

Genson

The Genson library claims to implement JSR-353.

https://code.google.com/p/genson/wiki/JSR353

I haven't tried this one myself though. I was recently also looking for a good JSON library, I tried 3 of them and finally settled with using Jackson as it best served my needs. The different thing is that I wasn't looking for a library which precisely implements the standard, I was just looking for something which is simple and does what I wanted it to do.


You can check Gson too, I guess (though it's not directly related to JSR-353).

https://code.google.com/p/google-gson/

Basil Bourque
  • 303,325
  • 100
  • 852
  • 1,154
peter.petrov
  • 38,363
  • 16
  • 94
  • 159
  • I was going to settle for Jackson but when i found out that it does not implement the standard that become impossible. And i cannot afford to use the application server to use its own implementation (if he has one which i doubt) so the need to have an API that does implement JSR-353 is mandatory unfortunately. When you say Gson is not directly related to JSR-353 you mean there is a chance that it could be ? – maher.belkh Jan 16 '15 at 13:26
  • @maher.belkh I mean, I don't see it in their docs that it's related. I am not sure. – peter.petrov Jan 16 '15 at 14:20
  • 2
    I am Genson author, indeed it implements jsr 353 and just works – eugen Jan 20 '15 at 08:20
  • Both project has moved to GitHub. New Genson page is [here](https://owlike.github.io/genson/Documentation/Extensions/#jsr-353---java-api-for-json-processing) and Gson moved [here](https://github.com/google/gson). – Franklin Yu Dec 20 '17 at 04:34
  • @eugen What about Genson supporting [JSR 374](https://jcp.org/en/jsr/detail?id=374), the successor to JSR 353? And does your binding feature implement [JSON-B](http://json-b.net) defined in JSR 367? I suggest adding to your [FAQ](http://genson.io/Faq/) to make this known. – Basil Bourque Feb 13 '19 at 20:51
  • @BasilBourque no it doesn't implement JSONB. – eugen Feb 13 '19 at 21:42