Announcement Announcement Module
Collapse
No announcement yet.
Newbie - Spring MVC / hibernate integration, asm incompatibility Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Newbie - Spring MVC / hibernate integration, asm incompatibility

    Hello,
    I'm quite new to spring and hibernate and i was trying to do some simple application, following tutorial, to access the data from my MySQL database.
    I'm using Netbeans7.2 with the framework Spring mvc and hibernate provided in this release and glassfish3.1

    When i try to acces the data, i have the message :
    exception
    org.springframework.web.util.NestedServletExceptio n: Handler processing failed; nested exception is java.lang.ExceptionInInitializerError
    root cause
    java.lang.NoSuchMethodError: org.objectweb.asm.ClassWriter.(I)V

    After few reserach and advice from the community, it appears that there is an incompatibility between the asm 3.1.1 of the spring MVC and the asm1.5.3 of hibernate

    If i've correctly understood, one solution is to use cglib-nodep2.2 instead of the cglib-2.1.3.jar (which as a dependency to asm1.5.3?)

    I've tried different things but still got the message : java.lang.NoSuchMethodError: org.objectweb.asm.ClassWriter.(I)V

    The inclusion in my class path are in the following order:
    • Spring 3.1.1 (containing cglib2.2 and asm3.1.1)
    • JSTL 1.1
    • mysql-connector5.1.18
    • Hibernate (containing cglib2.1.3, asm and asm-attribs)

    I've tried :
    • just adding the cglib-nodep2.2 to the path (last in classpath)
    • removing cglib2.1.3 (hibernate) and adding cglib-nodep2.2 in Hibernate
    • removing all cglib and asm (hibernate + spring) and adding cglib-nodep2.2 (first in classpath)
    • removing all cglib and asm (hibernate + spring) and adding cglib-nodep2.2 (second in classpath) and asm4.1 (first in classpath)

    Nothing works... Did i misunderstood the problem or i'm not adding / removing library from the classpath correctly ? (I had and remove library in the projet properties of NetBeans)
Working...
X