Our great sponsors
-
jsoniter
jsoniter (json-iterator) is fast and flexible JSON parser available in Java and Go (by json-iterator)
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
You gotta at least add the top contender. I mean dsl-json is probably the fastest json lib java has to offer. I personally like Rob's avaje-jsonb, because I think the approach of no reflection, and doing everything via annotation processing is rad. (it also has some decent speed too)
What about jsoniter?
First, there's benchmarks here if you haven't seen it: jvm-serializers. Not terribly scientific, but it's something. To make any decision, you really need to benchmark your own object graph and it's important to configure the serializer for your particular usage. Still, it is sort of useful for comparing frameworks. It would be interesting to see how Loial performs there. Ping me if you add it.
JsonBeans is similar to YamlBeans in how it does object marshaling, but uses a Ragel parser. I like Ragel and thought parsing JSON with it was neat, particularly that I could easily relax JSON parsing rules: "JavaScript" where the object property names are only quoted when needed or "minimal" where both object property names and values are only quoted when needed. Also commas are optional, as much as possible. The generic object graph was inspired by cJSON. JsonBeans is embedded in libgdx, so sees a lot of usage there. JSON isn't the right choice of data format if you want fast or efficient, so JsonBeans goal is only to be convenient.
https://github.com/quarkusio/qson also does code generation at build time using the Quarkus infrastructure and thus avoids reflection at runtime