Version 3

    bcel.jar issues

     

    If you get an exception that looks like the following:

     

    Depends On Me: , ObjectName: jboss.j2ee:service=EJB,jndiName=nukes/bb/ro/User
    state: FAILED
    I Depend On:
    Depends On Me: nukes.modules:name=bb
    java.lang.NoSuchMethodError: org.apache.bcel.generic.InstructionFactory.createNewArray
    (Lorg/apache/bcel/generic/Type;S)Lorg/apache/bcel/generic/Instruction;, ObjectName:
    jboss.j2ee:service=EJB,jndiName=nukes/bb/rw/User
    state: FAILED
    I Depend On:
    Depends On Me: nukes.modules:name=bb
    java.lang.NoSuchMethodError: org.apache.bcel.generic.InstructionFactory.createNewArray
    (Lorg/apache/bcel/generic/Type;S)Lorg/apache/bcel/generic/Instruction;]
    

     

    then somewhere there is another copy of bcel.jar available that is conflicting with the version in jboss's lib directory. The most common culprit is having a copy of xalan.jar in your JAVA_HOME/jre/lib/endorsed directory.

     

    -


    27.04.04: pd

    I found as reason the xsltc.jar in Java_HOME\jre\lib\endorsed which contains a previous version of the org.apache.bcel.generic.InstructionFactory class with a createNewArray() method having a different signature. Remove the older copies of xsltc.jar and it will work.