I am doing a project of educational purposes on spring + hibernate. By examples, I wrote part of the functionality, but I specified Spring 4.1.5 and hibernate 4 in dependencies. Errors occurred with the creation of beans.

Then I learned that there might be issues with version compatibility and replaced versions with spring 3.0.5 and hibernate 3.3.0. But these versions work on java 7, but now everyone switched to 8 and 9? (I may be wrong, correct). And the project on such versions also does not start (One error remains, it is solved by rolling back to java 7).

Hence the question: How to write on spring + hibernate in our days? What versions of these frameworks are compatible? I just can not find a good article with an example of the proper creation of the Context and the Beans on this bundle. I would be grateful for any help.

  • I had a similar problem. The solution in such cases is found by copying an error message to the search engine. The search result should lead to the appropriate topic on StackOverflow, because you are not the first to encounter such a problem. - Nikolay Belyakov
  • @NikolaiBelyakov, I did just that :) Just this helped to solve the errors of creating bins, but it led to an error, which is solved by rolling back to java 7, but I’m interested in compatibility under 8 Java (9) let's not touch) - alex.stepan
  • I have projects for Spring 4 and Hibernate 4 that are perfectly compiled and run in Java 9. You have a problem with something else. - Sergey Gornostaev
  • @SergeyGornostaev; Probably, the problem is in raising the context (if I correctly express it). The fact is that I did the project following the example from the third spring, there are settings in the xml files. But somewhere I read that now they are leaving this, perhaps this is the problem. Specifically, I have xml on github - alex.stepan
  • What exactly the problem can be determined only by the error of the frame. Problems with the use of xml-configurations today. - Sergey Gornostaev

0