Open ankitbardiyasapiens opened 1 year ago
The Hibernate extension was once brought in as contribution, personally I never used it in a real project. So you may help with patches upgrading the head revision to the latest Hibernate version...
I took this on, but it is a quick solution that is not ready to be added to Xstream.
This is what I did:
My plan is to implement this using a smarter approach, i.e works with Hibernate 4 or 6 and do proper testing. I hope to get to that soon, but this hack should get you going for now.
I also want to point out that I could not update the HEAD (1.5.0-SNAPSHOT) version since it would not build for me. I was consistently getting errors with the Lambda test cases, among others. Once HEAD is in a better state, I can add the updates.
Just as a side note, master builds for me cleanly using Java 17 including execution of all unit tests. However, for the next two weeks I am offline, so don't expect any response for this time. BTW: Do you have any numbers about the usage of the different major Hibernate versions? O simply wonder, what XStream 1.5 should support. 3+4 are probably completely out of scope...
Okay, I can confirm that everything builds and passes tests with Java 17. I think I was using Java 21 instead, which does not build successfully. Please note that OpenJDK 17 is successful, but Oracle JDK 17 is not.
It should be easy to support all major hibernate versions. The code can try for 6 first, and if it fails, fall back to 3/4.
Sorry for the delay, I have this on my radar, but I am currently still overloaded...
We are doing a major upgrade on our application including hibernate 6. We use xstream for a very critial part of our application so we are looking for an upgrade since xstream-hibernate 1.4.20 still using hibernate 4 only.