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
Unable to use JiBX with Java 8 #3
Comments
Yes please, when will this be fixed? |
I debugged the code and the Problem is related to BCEL.
|
+1 |
1 similar comment
+1 |
Perhaps JiBX should move to a different bytecode library such as ASM, Byteman, or Byte Buddy. It appears BCEL hasn't seen any activity in quite a while. |
I am not so sure this could be done that easy. do you have knowledge in one of these tools you are refering? You could give it a try. |
I made an attempt to port over to ASM, spent 2 days, could not port all the code and therefore gave up. I estimated that it would take about 6 weeks to complete the port. I contacted Dennis Sosnosky, the original developer of JiBX and he confirmed that he has no plans of upgrading to Java 8 because his estimate was 8-12 weeks and he could not afford to invest that much effort outside of his regular work hours. Dennis also mentioned that he had made a proposal on the JiBX users list to sponsor a project for him to port over to ASM but no one showed interest. My team got convinced last year that there was no surety around JiBX getting ported to Java 8. So, we branched off our production application, got rid of JiBX and plugged in JAXB in its place. Then we ran some performance tests against our master branch using JiBX and JDK 7 and the new branch using JAXB and JDK 8. We did not find any conclusive evidence of a performance difference between the two. Our most complicated use case involves importing a file containing 36,000+ products with each product having over 200 attributes in the XML file. We did not find much practical difference between JiBX and JAXB with this file. Also, all our XML serialization-deserialization use cases are infrequent so there was no real reason to worry too much about performance. We therefore migrated to JAXB immediately and have not seen any apparent problems so far. All our XML manipulation code is in a single class that is invoked from multiple places. Therefore, we had to change only one file and we were done. For teams using a similar approach, migration to JAXB may be a viable option, given that JAXB is now part of the standard JDK and therefore guaranteed to get upgraded with Java versions. For those looking for an example, here is our code (comments and some sensitive parts ommitted):
|
I have re-code the binding part of Jibx with Javassist, and it support JDK1.8. See my project: https://github.com/passyt/jibx-bind |
FYI, JiBX 1.2.6 binding now works on Java 1.8. You have to use the latest 6.0-SNAPSHOT of the BCEL library, which is available here. However and weirdly, it works for me on Linux, but not on Mac OS X. I'm using OpenJDK 1.8.0_60-b27 on Linux and Oracle Java 1.8.0_60-b27 on Mac OS X. On Mac OS X I'm still getting the |
check your environment. if using Ant, please remove any references to Regards, Mark Thomas "Commit to the Lord whatever you do, On Fri, Oct 2, 2015 at 12:56 PM, Archie L. Cobbs notifications@github.com
|
Thanks! That was indeed the problem. This fixed it:
FYI I'm using |
you're welcome Regards, Mark Thomas "Commit to the Lord whatever you do, On Fri, Oct 2, 2015 at 1:20 PM, Archie L. Cobbs notifications@github.com
|
Hi All, Since past July, BCEL 6.0 is available so I suppose new version could be realease with this dependency. |
It‘s a good news. |
JiBX 1.3.0-SNAPSHOT has been released. Thanks to the new BCEL release, JiBX is now compatible with JDK 1.6, 1.7, and 1.8. You can find the jar file here: The snapshot is in the maven central snapshot repo. You can browse maven snapshots here: To use a snapshot in your pom file, add a repository section: <repositories>
<repository>
<id>central</id>
<name>Maven Repository Switchboard</name>
<layout>default</layout>
<url>http://repo1.maven.org/maven2</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>central-snapshot</id>
<name>Central Repository</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<layout>default</layout>
<snapshots>
<enabled>true</enabled>
</snapshots>
<releases>
<enabled>false</enabled>
</releases>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<name>Maven Plugin Repository</name>
<url>http://repo1.maven.org/maven2</url>
<layout>default</layout>
<snapshots>
<enabled>false</enabled>
</snapshots>
<releases>
<updatePolicy>never</updatePolicy>
</releases>
</pluginRepository>
<pluginRepository>
<id>central-snapshot</id>
<name>Central Repository</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<layout>default</layout>
<snapshots>
<enabled>true</enabled>
</snapshots>
<releases>
<enabled>false</enabled>
</releases>
</pluginRepository>
</pluginRepositories> Test it. Log your issues here: It looks pretty solid. I should be able to put out a release in a few weeks. @dcorleyusc |
Fixed! |
on maven , we should update maven-jibx-plugin to 1.3.1 org.jibx |
Java: Oracle JDK 1.8.0.0, Oracle JDK 1.8.0.05, OpenJDK 1.8.0
OS: 64-bit CentOS, 64-bit RedHat, 64-bit Amazon Linux, 64-bit Fedora, 64-bit Windows 7 Professional, 64-bit Windows 8 Pro
JiBX: 1.2.5
We are trying to upgrade our applications (around 60 in number) to Java 8. All of them use JiBX and JiBX Maven plugin version 1.2.5. The following error is received during the Maven builds and the builds fail:
This problem has existed since the first OpenJDK developer preview came out and has been reported in several forums. What are the plans to fix this?
The text was updated successfully, but these errors were encountered: