SSH configuration error learning (1)-java. Lang. nosuchmethoderror

Source: Internet
Author: User
Environment: eclipse3.3.0 + myeclipse5.5.1ga (spring2.0 + struts1.1 + hibernate3.1)

The error is: Java. Lang. nosuchmethoderror
Code:
15:20:54, 093 error contextloader: 203-context initialization failed
Org. springframework. beans. factory. beancreationexception: Error creating bean with name 'sessionfactory 'defined in class path resource [applicationcontext. XML]: Invocation of init method failed; Nested exception is Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
Caused:
Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
At net. SF. cglib. Core. classemitter. begin_class (classemitter. Java: 77)
At net. SF. cglib. Core. keyfactory $ generator. generateclass (keyfactory. Java: 173)
At net. SF. cglib. Core. defaultgeneratorstrategy. Generate (defagenergeneratorstrategy. Java: 25)
At net. SF. cglib. Core. abstractclassgenerator. Create (abstractclassgenerator. Java: 216)
At net. SF. cglib. Core. keyfactory $ generator. Create (keyfactory. Java: 145)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 117)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 108)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 104)
At net. SF. cglib. Proxy. enhancer. (enhancer. Java: 69)
At org. hibernate. Proxy. pojo. cglib. cgliblzyinitializer. getproxyfactory (cgliblzyinitializer. Java: 107)
At org. hibernate. Proxy. pojo. cglib. cglibproxyfactory. postinstantiate (cglibproxyfactory. Java: 43)
At org. hibernate. tuple. entity. pojoentitytuplizer. buildproxyfactory (pojoentitytuplizer. Java: 162)
At org. hibernate. tuple. entity. abstractentitytuplizer. (abstractentitytuplizer. Java: 135)
At org. hibernate. tuple. entity. pojoentitytuplizer. (pojoentitytuplizer. Java: 55)
At org. hibernate. tuple. entity. entityentitymodetotuplizermapping. (entityentitymodetotuplizermapping. Java: 56)
At org. hibernate. tuple. entity. entitymetamodel. (entitymetamodel. Java: 295)
At org. hibernate. persister. entity. abstractentitypersister. (abstractentitypersister. Java: 434)
At org. hibernate. persister. entity. singletableentitypersister. (singletableentitypersister. Java: 109)
At org. hibernate. persister. persisterfactory. createclasspersister (persisterfactory. Java: 55)
At org. hibernate. impl. sessionfactoryimpl. (sessionfactoryimpl. Java: 226)
At org. hibernate. cfg. configuration. buildsessionfactory (configuration. Java: 1294)
At org. springframework. Orm. hibernate3.localsessionfactorybean. newsessionfactory (localsessionfactorybean. Java: 805)
At org. springframework. Orm. hibernate3.localsessionfactorybean. buildsessionfactory (localsessionfactorybean. Java: 745)
At org. springframework. Orm. hibernate3.abstractsessionfactorybean. afterpropertiesset (abstractsessionfactorybean. Java: 134)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. invokeinitmethods (abstractautowirecapablebeanfactory. Java: 1202)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. initializebean (abstractautowirecapablebeanfactory. Java: 1172)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. createbean (abstractautowirecapablebeanfactory. Java: 428)
At org. springframework. Beans. Factory. Support. abstractbeanfactory $1. GetObject (abstractbeanfactory. Java: 251)
At org. springframework. Beans. Factory. Support. defaultsingletonbeanregistry. getsingleton (defaultsingletonbeanregistry. Java: 156)
At org. springframework. Beans. Factory. Support. abstractbeanfactory. getbean (abstractbeanfactory. Java: 248)
At org. springframework. Beans. Factory. Support. abstractbeanfactory. getbean (abstractbeanfactory. Java: 160)
At org. springframework. Beans. Factory. Support. defaultlistablebeanfactory. preinstantiatesingletons (defaultlistablebeanfactory. Java: 284)
At org. springframework. Context. Support. abstractapplicationcontext. Refresh (abstractapplicationcontext. Java: 352)
At org. springframework. Web. Context. contextloader. createwebapplicationcontext (contextloader. Java: 244)
At org. springframework. Web. Context. contextloader. initwebapplicationcontext (contextloader. Java: 187)
At org. springframework. Web. Context. contextloaderservlet. INIT (contextloaderservlet. Java: 82)
At javax. servlet. genericservlet. INIT (genericservlet. Java: 212)
At org. Apache. Catalina. Core. standardwrapper. loadservlet (standardwrapper. Java: 1139)
At org. Apache. Catalina. Core. standardwrapper. Load (standardwrapper. Java: 966)
At org. Apache. Catalina. Core. standardcontext. loadonstartup (standardcontext. Java: 3956)
At org. Apache. Catalina. Core. standardcontext. Start (standardcontext. Java: 4230)
At org. Apache. Catalina. Core. containerbase. addchildinternal (containerbase. Java: 760)
At org. Apache. Catalina. Core. containerbase. addchild (containerbase. Java: 740)
At org. Apache. Catalina. Core. standardhost. addchild (standardhost. Java: 544)
At org. Apache. Catalina. startup. hostconfig. deploydirectory (hostconfig. Java: 920)
At org. Apache. Catalina. startup. hostconfig. deploydirectories (hostconfig. Java: 883)
At org. Apache. Catalina. startup. hostconfig. deployapps (hostconfig. Java: 492)
At org. Apache. Catalina. startup. hostconfig. Start (hostconfig. Java: 1138)
At org. Apache. Catalina. startup. hostconfig. lifecycleevent (hostconfig. Java: 311)
At org. Apache. Catalina. util. lifecyclesupport. firelifecycleevent (lifecyclesupport. Java: 120)
At org. Apache. Catalina. Core. containerbase. Start (containerbase. Java: 1022)
At org. Apache. Catalina. Core. standardhost. Start (standardhost. Java: 736)
At org. Apache. Catalina. Core. containerbase. Start (containerbase. Java: 1014)
At org. Apache. Catalina. Core. standardengine. Start (standardengine. Java: 443)
At org. Apache. Catalina. Core. standardservice. Start (standardservice. Java: 448)
At org. Apache. Catalina. Core. standardserver. Start (standardserver. Java: 700)
At org. Apache. Catalina. startup. Catalina. Start (Catalina. Java: 552)
At sun. Reflect. nativemethodaccessorimpl. invoke0 (native method)
At sun. Reflect. nativemethodaccessorimpl. Invoke (nativemethodaccessorimpl. Java: 39)
At sun. Reflect. delegatingmethodaccessorimpl. Invoke (delegatingmethodaccessorimpl. Java: 25)
At java. Lang. Reflect. method. Invoke (method. Java: 585)
At org. Apache. Catalina. startup. Bootstrap. Start (Bootstrap. Java: 295)
At org. Apache. Catalina. startup. Bootstrap. Main (Bootstrap. Java: 433)
15:20:54, 109 error [/esreport]: 676-standardwrapper. throwable
Org. springframework. beans. factory. beancreationexception: Error creating bean with name 'sessionfactory 'defined in class path resource [applicationcontext. XML]: Invocation of init method failed; Nested exception is Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
Caused:
Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
At net. SF. cglib. Core. classemitter. begin_class (classemitter. Java: 77)
At net. SF. cglib. Core. keyfactory $ generator. generateclass (keyfactory. Java: 173)
At net. SF. cglib. Core. defaultgeneratorstrategy. Generate (defagenergeneratorstrategy. Java: 25)
At net. SF. cglib. Core. abstractclassgenerator. Create (abstractclassgenerator. Java: 216)
At net. SF. cglib. Core. keyfactory $ generator. Create (keyfactory. Java: 145)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 117)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 108)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 104)
At net. SF. cglib. Proxy. enhancer. (enhancer. Java: 69)
........................................ ........................................ (Omitted)

Cause: Some jar files shared by spring and hibernate have version conflicts.
Solution: Delete the WEB-INF/lib/asm-2.2.3.jar and restart tomcat.

The error is: Java. Lang. nosuchmethoderror
Code:
15:20:54, 093 error contextloader: 203-context initialization failed
Org. springframework. beans. factory. beancreationexception: Error creating bean with name 'sessionfactory 'defined in class path resource [applicationcontext. XML]: Invocation of init method failed; Nested exception is Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
Caused:
Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
At net. SF. cglib. Core. classemitter. begin_class (classemitter. Java: 77)
At net. SF. cglib. Core. keyfactory $ generator. generateclass (keyfactory. Java: 173)
At net. SF. cglib. Core. defaultgeneratorstrategy. Generate (defagenergeneratorstrategy. Java: 25)
At net. SF. cglib. Core. abstractclassgenerator. Create (abstractclassgenerator. Java: 216)
At net. SF. cglib. Core. keyfactory $ generator. Create (keyfactory. Java: 145)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 117)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 108)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 104)
At net. SF. cglib. Proxy. enhancer. (enhancer. Java: 69)
At org. hibernate. Proxy. pojo. cglib. cgliblzyinitializer. getproxyfactory (cgliblzyinitializer. Java: 107)
At org. hibernate. Proxy. pojo. cglib. cglibproxyfactory. postinstantiate (cglibproxyfactory. Java: 43)
At org. hibernate. tuple. entity. pojoentitytuplizer. buildproxyfactory (pojoentitytuplizer. Java: 162)
At org. hibernate. tuple. entity. abstractentitytuplizer. (abstractentitytuplizer. Java: 135)
At org. hibernate. tuple. entity. pojoentitytuplizer. (pojoentitytuplizer. Java: 55)
At org. hibernate. tuple. entity. entityentitymodetotuplizermapping. (entityentitymodetotuplizermapping. Java: 56)
At org. hibernate. tuple. entity. entitymetamodel. (entitymetamodel. Java: 295)
At org. hibernate. persister. entity. abstractentitypersister. (abstractentitypersister. Java: 434)
At org. hibernate. persister. entity. singletableentitypersister. (singletableentitypersister. Java: 109)
At org. hibernate. persister. persisterfactory. createclasspersister (persisterfactory. Java: 55)
At org. hibernate. impl. sessionfactoryimpl. (sessionfactoryimpl. Java: 226)
At org. hibernate. cfg. configuration. buildsessionfactory (configuration. Java: 1294)
At org. springframework. Orm. hibernate3.localsessionfactorybean. newsessionfactory (localsessionfactorybean. Java: 805)
At org. springframework. Orm. hibernate3.localsessionfactorybean. buildsessionfactory (localsessionfactorybean. Java: 745)
At org. springframework. Orm. hibernate3.abstractsessionfactorybean. afterpropertiesset (abstractsessionfactorybean. Java: 134)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. invokeinitmethods (abstractautowirecapablebeanfactory. Java: 1202)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. initializebean (abstractautowirecapablebeanfactory. Java: 1172)
At org. springframework. Beans. Factory. Support. abstractautowirecapablebeanfactory. createbean (abstractautowirecapablebeanfactory. Java: 428)
At org. springframework. Beans. Factory. Support. abstractbeanfactory $1. GetObject (abstractbeanfactory. Java: 251)
At org. springframework. Beans. Factory. Support. defaultsingletonbeanregistry. getsingleton (defaultsingletonbeanregistry. Java: 156)
At org. springframework. Beans. Factory. Support. abstractbeanfactory. getbean (abstractbeanfactory. Java: 248)
At org. springframework. Beans. Factory. Support. abstractbeanfactory. getbean (abstractbeanfactory. Java: 160)
At org. springframework. Beans. Factory. Support. defaultlistablebeanfactory. preinstantiatesingletons (defaultlistablebeanfactory. Java: 284)
At org. springframework. Context. Support. abstractapplicationcontext. Refresh (abstractapplicationcontext. Java: 352)
At org. springframework. Web. Context. contextloader. createwebapplicationcontext (contextloader. Java: 244)
At org. springframework. Web. Context. contextloader. initwebapplicationcontext (contextloader. Java: 187)
At org. springframework. Web. Context. contextloaderservlet. INIT (contextloaderservlet. Java: 82)
At javax. servlet. genericservlet. INIT (genericservlet. Java: 212)
At org. Apache. Catalina. Core. standardwrapper. loadservlet (standardwrapper. Java: 1139)
At org. Apache. Catalina. Core. standardwrapper. Load (standardwrapper. Java: 966)
At org. Apache. Catalina. Core. standardcontext. loadonstartup (standardcontext. Java: 3956)
At org. Apache. Catalina. Core. standardcontext. Start (standardcontext. Java: 4230)
At org. Apache. Catalina. Core. containerbase. addchildinternal (containerbase. Java: 760)
At org. Apache. Catalina. Core. containerbase. addchild (containerbase. Java: 740)
At org. Apache. Catalina. Core. standardhost. addchild (standardhost. Java: 544)
At org. Apache. Catalina. startup. hostconfig. deploydirectory (hostconfig. Java: 920)
At org. Apache. Catalina. startup. hostconfig. deploydirectories (hostconfig. Java: 883)
At org. Apache. Catalina. startup. hostconfig. deployapps (hostconfig. Java: 492)
At org. Apache. Catalina. startup. hostconfig. Start (hostconfig. Java: 1138)
At org. Apache. Catalina. startup. hostconfig. lifecycleevent (hostconfig. Java: 311)
At org. Apache. Catalina. util. lifecyclesupport. firelifecycleevent (lifecyclesupport. Java: 120)
At org. Apache. Catalina. Core. containerbase. Start (containerbase. Java: 1022)
At org. Apache. Catalina. Core. standardhost. Start (standardhost. Java: 736)
At org. Apache. Catalina. Core. containerbase. Start (containerbase. Java: 1014)
At org. Apache. Catalina. Core. standardengine. Start (standardengine. Java: 443)
At org. Apache. Catalina. Core. standardservice. Start (standardservice. Java: 448)
At org. Apache. Catalina. Core. standardserver. Start (standardserver. Java: 700)
At org. Apache. Catalina. startup. Catalina. Start (Catalina. Java: 552)
At sun. Reflect. nativemethodaccessorimpl. invoke0 (native method)
At sun. Reflect. nativemethodaccessorimpl. Invoke (nativemethodaccessorimpl. Java: 39)
At sun. Reflect. delegatingmethodaccessorimpl. Invoke (delegatingmethodaccessorimpl. Java: 25)
At java. Lang. Reflect. method. Invoke (method. Java: 585)
At org. Apache. Catalina. startup. Bootstrap. Start (Bootstrap. Java: 295)
At org. Apache. Catalina. startup. Bootstrap. Main (Bootstrap. Java: 433)
15:20:54, 109 error [/esreport]: 676-standardwrapper. throwable
Org. springframework. beans. factory. beancreationexception: Error creating bean with name 'sessionfactory 'defined in class path resource [applicationcontext. XML]: Invocation of init method failed; Nested exception is Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
Caused:
Java. lang. nosuchmethoderror: Org. objectweb. ASM. classvisitor. visit (iiljava/lang/string; ljava/lang/string; [ljava/lang/string;) V
At net. SF. cglib. Core. classemitter. begin_class (classemitter. Java: 77)
At net. SF. cglib. Core. keyfactory $ generator. generateclass (keyfactory. Java: 173)
At net. SF. cglib. Core. defaultgeneratorstrategy. Generate (defagenergeneratorstrategy. Java: 25)
At net. SF. cglib. Core. abstractclassgenerator. Create (abstractclassgenerator. Java: 216)
At net. SF. cglib. Core. keyfactory $ generator. Create (keyfactory. Java: 145)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 117)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 108)
At net. SF. cglib. Core. keyfactory. Create (keyfactory. Java: 104)
At net. SF. cglib. Proxy. enhancer. (enhancer. Java: 69)
........................................ ........................................ (Omitted)

Cause: Some jar files shared by spring and hibernate have version conflicts.
Solution: Delete the WEB-INF/lib/asm-2.2.3.jar and restart tomcat.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.