Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON benchmark for Boon fails on Java 9+ #2

Open
kausandr opened this issue Jun 8, 2021 · 0 comments
Open

JSON benchmark for Boon fails on Java 9+ #2

kausandr opened this issue Jun 8, 2021 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@kausandr
Copy link
Contributor

kausandr commented Jun 8, 2021

Boon lib fails to initialize when running on Java versions 9+. It throws an exception:

java.lang.ExceptionInInitializerError
        at org.boon.json.JsonMappingParser.<init>(JsonMappingParser.java:85)
        at org.boon.json.JsonParserFactory.create(JsonParserFactory.java:228)
        at org.boon.json.implementation.ObjectMapperImpl.readValue(ObjectMapperImpl.java:67)
        at com.gocypher.cybench.jmh.jvm.client.tests.JsonLibraryBenchmark$BoonDeserialize.doJob(JsonLibraryBenchmark.java:779)
        at com.gocypher.cybench.jmh.jvm.client.tests.JsonLibraryBenchmark.boonWithAverageJSON(JsonLibraryBenchmark.java:357)
        at com.gocypher.cybench.jmh.jvm.client.tests.jmh_generated.JsonLibraryBenchmark_boonWithAverageJSON_jmhTest.boonWithAverageJSON_thrpt_jmhStub(JsonLibraryBenchmark_boonWithAverageJSON_jmhTest.java:179)
        at com.gocypher.cybench.jmh.jvm.client.tests.jmh_generated.JsonLibraryBenchmark_boonWithAverageJSON_jmhTest.boonWithAverageJSON_Throughput(JsonLibraryBenchmark_boonWithAverageJSON_jmhTest.java:111)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.openjdk.jmh.runner.BenchmarkHandler$BenchmarkTask.call(BenchmarkHandler.java:453)
        at org.openjdk.jmh.runner.BenchmarkHandler$BenchmarkTask.call(BenchmarkHandler.java:437)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.ClassCastException: class [B cannot be cast to class [C ([B and [C are in module java.base of loader 'bootstrap')
        at org.boon.core.reflection.FastStringUtils$StringImplementation$1.toCharArray(FastStringUtils.java:92)
        at org.boon.core.reflection.FastStringUtils.toCharArray(FastStringUtils.java:175)
        at org.boon.primitive.Chr.chars(Chr.java:70)
        at org.boon.json.implementation.JsonParserCharArray.<clinit>(JsonParserCharArray.java:275)
        ... 19 more

See Boon open issue.

It may be some other libs not supporting Java 9+ and already being unsupported for a long time. Last Boon release and commit dates back to 2016.

So some benchmarks may be dependent on runner JVM version: e.g Boon benchmarks run only if runner Java is 1.8.

@kausandr kausandr added the bug Something isn't working label Jun 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants