-
Notifications
You must be signed in to change notification settings - Fork 65
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
Serialization/Deserialization of generics broken with java 10 #140
Comments
|
Could you try to configuring Genson slightly differently by disabling: |
I can not test #141 as it does not compile on my machine. I checked out the genson-parent, applied the change of the ASM version and tried to mvn install, which lead to a lot of errors.
|
If there is a build system where i can download an pre-built artifact, i could try to use that. |
Eh Looks like other libs that are being used during testing might not be compatible with java 10 :/ |
If you use intellij, its quite easy to get a java10-compatible project. Just create a module-info.java in src/main/java with content like this: |
any news on that? a binary (.jar etc.) with the new asm version as dependency could maybe help to use it at least as unnamed module. unfortunately, i can not build it with java 11. i get many errors |
I didn't have the time to look more into that for now. I deployed a snapshot version here https://oss.sonatype.org/content/repositories/snapshots/com/owlike/genson/1.5-SNAPSHOT/. You should be able to refer to it just as you would do with any other dependency. Note that it was built using java 8. Let me know if this works for you. |
I got it working with some modifications. I will create a fork of the repo so you can maybe work with that. Whats now missing (did not get it working) was the maven-bundle-plugin, something wrong with the MANIFEST.MF The local installed version seem now to work with java10/11, but required asm7-beta |
only changing the asm version in the pom did not work, see #142 |
So you tried depending on this snapshot version of Genson and you got some errors? If so what error did you get? I'd imagine that there are high chances that code compiled for Java 8 should be compatible with Java 11. |
Thats really wierd now. I recieved an error yesterday evening something with: "This feature requires ASM6", checked the changelog of asm7 (support of JDK 11 features now official (was experimental) - so i thought i just go to 7-beta to see what happens. I checked the file ASMCreatorParameterNameResolver.java which has a nested class which extends ClassVisitor. With your pull request, the API version of that class (first parameter) is 5. At the moment it makes no sense to me why it should work with only updating the module, but i deleted my .m2 cache and it still works. Also checked the source of the .jar i use now, this also initializes the class with ASM5. |
I also ran into this problem using Java 11. Jetty updated to ASM 7.0 [1] in order to run on Java 11 @EugenCepoi IMHO this is a very important feature for Genson. Any update on Java 11 support? [1] https://www.eclipse.org/lists/jetty-announce/msg00125.html |
How could I test? Any development build available? |
Hey @martin-petzold, I've somewhat stopped investing time in Genson. But if you had the desire to work on a fix and submit a PR, I could do a release with it. |
This code does not work. Can someone tell me why?
I use Java10 with modules
I created a java 8 Test-Project with the source above and it worked as expected. In that case, genson does not work with java 10, very sad. For me a show stopper. So i need to find something like genson which works with java 10 modules.
The text was updated successfully, but these errors were encountered: