Today, we need to integrate a scientific research system. After integration, the following error occurs:
Java. Lang. noclassdeffounderror: ORG/hibernate/CFG/hbmbinder $ secondpass
Baidu once saw a post posted by sunshineray on javaeye and posted it:
Google, found that many people say that the direct deletion: Lib under the hibernate-annotations.jar can, I did, indeed successfully solved this problem, but I don't know why. After finding a lot of methods, I will probably find out the specific reasons.
First, I searched for annotations. Jar locally and found that it appears twice in myeclipse:
Myeclipse/Eclipse/plugins/com.genuitec.org. hibernate. Eclipse/lib/Annotations-223 m
Myeclipse/Eclipse/plugins/COM. genuitec. Eclipse. springframework/data/1.2/lib/dependencies/hibernate-128 m
Obviously, this version of M is an old version. It indicates that hibernate contains an old version of jar package in spring1.2, which causes this problem. The solution is very simple.
1. Delete the hibernate-annotations.jar of the old version in Lib.
2. Copy the jar package of 223m to Lib.
3. or overwrite the jar package of 223m to MB!