Weblogic8.1 + hibernate3.0: the following error occurs when Weblogic is started: charscanner; panic: classnotfoundexception: org. hibernate. hql. Ast. hqltoken. Then the server crashes directly.
Solution: Add a property hibernate. query. factory_class to hibernate. hql. Classic. classicquerytranslatorfactory in hibernate. properties or conext XML of spring. The value is org. hibernate. hql. Classic. classicquerytranslatorfactory. This method cannot solve the problem, resulting in hql parsing errors. (Cause: anlr is required in hibernate3, but this package is in weblogic. jar contains the antrl class library, and some class loading errors will occur. The hibernate3.jar in war or ear cannot be found.
After this error occurs, anlr will call system. Exit (), so that WebLogic will stop the service .)
Solution:
Find D:/BEA/user_projects/domains/domain1/setenv. BAT (the UNIX platform is setenv. Sh)
View set wl_home = D:/BEA/weblogic81
Add antlr-2.7.5H3.jar to the beginning, loaded prior to weblogic. Jar
Set classpath = % wl_home %/Server/lib/antlr-2.7.5H3.jar;
Restart and solve the problem.
If eclipse + Weblogic8.1 + hibernate3.0, preferences-> Weblogic-> weblogic8.x-> paths-> prepend to classpath, add the antlr-2.7.5H3.jar, preferably load this jar package, (append to classpath is the last loaded jar package .)