Announcement Announcement Module
Collapse
No announcement yet.
Error:specify custom LTW or start JVM with spring agent.jar Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Error:specify custom LTW or start JVM with spring agent.jar

    Hi, I see this error on my Linux box.
    Code:
    2012-03-16 04:53:11,801 INFO  [Thread-2] org.springframework.beans.factory.support.DefaultSingletonBeanRegistry (DefaultSingletonBeanRegistry.java:421) - Destroying singletons in org.springframework.beans.factory.support.DefaultListableBeanFactory@4ab57441: defining beans [regression-test-framework-context,configLocations]; root of factory hierarchy
    2012-03-16 04:53:11,802 ERROR [Thread-2] org.springframework.web.context.ContextLoader (ContextLoader.java:215) - Context initialization failed
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'regression-test-framework-context' defined in ServletContext resource [/WEB-INF/application-context-web-config.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.context.support.ClassPathXmlApplicationContext]: Constructor threw exception; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.context.weaving.AspectJWeavingEnabler#0': Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loadTimeWeaver': Initialization of bean failed; nested exception is java.lang.IllegalStateException: ClassLoader [org.apache.catalina.loader.WebappClassLoader] does NOT provide an 'addTransformer(ClassFileTransformer)' method. Specify a custom LoadTimeWeaver or start your Java virtual machine with Spring's agent: -javaagent:spring-agent.jar
            at org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:254)
    I did set the JAVA_OPTS in catalina.sh file.But still see the same error.Can any one please tell me what could possibly be wrong?

    I do have spring-agent-2.5.6.jar,spring-tomcat-weaver.jar,aspectjweaver-1.6.1.jar in my tomcat/lib folder.

    if [ -z "$LOGGING_MANAGER" ]; then
    JAVA_OPTS="$JAVA_OPTS -Djava.util.logging.manager=org.apache.juli.ClassLo aderLogManager " -javaagent:spring-agent-2.5.6.jar" " -Djava.library.path=/opt/RTF/invison_libs/""
    else
    JAVA_OPTS="$JAVA_OPTS $LOGGING_MANAGER"
    fi
Working...
X