My OC4J application deployment fails with a NoSuchMethodError: org.objectweb.asm.ClassVisitor.visit.- The OC4J deployment fails with the error: Initialization of bean failed; nested exception is java.lang.NoSuchMethodError: org.objectweb.asm.ClassVisitor.visit(IILjava/lang/String;Ljava/lang/Strin;gString[Ljava/lang/String;Ljava/lang/String;)
ANSWER: - The issue is that multiple (and old) versions of the "asm" jar are being deployed. Do the following:
- remove dependencies asm and cglib from the project pom.xml file.
- add dependency for cglib-nodep version 2.2.2 in your project pom.xml (this pulls in asm).
- put in exclusions for any other indirect dependencies of cglib and asm.
|