The libraries that implement JSR-353,374 (javax.json, johnzon) were using GensonJsonProvider.
The Genson library has a javax.json.spi.JsonProvider set on META-INF.services, which will return a GensonJsonProvider on the JsonProvider.provider() call.
(GensonJsonProvider does not implement JSR-374.)
I added a javax.json.spi.JsonProvider to META-INF.services so that I could select a JsonProvider implementation. The default implementation uses org.glassfish.json.JsonProviderImpl.
In case of johnzon, JsonReaderFactory and JsonGeneratorFactory are injected directly into UsersJsonProvider to use johnson's own JsonProvider.
Now, in the benchmark test, the javaxjson() test will use org.glassfish.json.JsonProviderImpl and johnzon() will use org.apache.johnzon.core.JsonProviderImpl.
The libraries that implement JSR-353,374 (javax.json, johnzon) were using GensonJsonProvider. The Genson library has a
javax.json.spi.JsonProvider
set onMETA-INF.services
, which will return a GensonJsonProvider on theJsonProvider.provider()
call. (GensonJsonProvider does not implement JSR-374.)I added a
javax.json.spi.JsonProvider
toMETA-INF.services
so that I could select a JsonProvider implementation. The default implementation usesorg.glassfish.json.JsonProviderImpl
. In case of johnzon, JsonReaderFactory and JsonGeneratorFactory are injected directly into UsersJsonProvider to use johnson's own JsonProvider.Now, in the benchmark test, the
javaxjson()
test will useorg.glassfish.json.JsonProviderImpl
andjohnzon()
will useorg.apache.johnzon.core.JsonProviderImpl
.