I have been running into the same deployment problem for the last day or two now. I'm
not sure if it is related to how my deployment is structured or it's a simple
configuration step I missed.
My Situation:
-Running JBoss 4.0.5GA
-Using the JBoss AOP tool inside JBoss IDE
-Copied the jboss-aop-jdk50.deployer into my deploy directory (removing the regular
jboss-aop.deployer)
-Set EnableLoadTimeWeaving to true
-Added the pluggable-instrumentor.jar to JBOSS_HOME\bin directory
-Added -javaagent:pluggable-instrumentor.jar to my run.bat
-Created a .aop archive that contains only one file META-INF/jboss-aop.xml
-Added the .aop archive to the top of the list in my application.xml file
The server startup is fine with the exception of some exceptions that are not generated
from my application:
12:06:02,753 ERROR [STDERR] [warn] AOP Instrumentor failed to transform
org.apache.catalina.core.StandardServer
| 12:06:02,753 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed
to aspectize class org.apache.catalina.core.StandardSer
| ver. Could not find class it references
org.apache.catalina.core.NamingContextListener It may not be in your classpath and you
may not be
| getting field and constructor weaving for this class.
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.instrument.Instrumentor.convertReferences(Instrumentor.java:666)
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.instrument.Instrumentor.transform(Instrumentor.java:720)
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.AspectManager.translate(AspectManager.java:908)
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.AspectManager.transform(AspectManager.java:820)
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.standalone.AOPTransformer.aspectTransform(AOPTransformer.java:88)
| 12:06:02,753 ERROR [STDERR] at
org.jboss.aop.standalone.AOPTransformer.transform(AOPTransformer.java:75)
| 12:06:02,753 ERROR [STDERR] at
sun.instrument.TransformerManager.transform(TransformerManager.java:122)
| 12:06:02,753 ERROR [STDERR] at
sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:155)
| 12:06:02,753 ERROR [STDERR] at java.lang.ClassLoader.defineClass1(Native Method)
| 12:06:02,753 ERROR [STDERR] at
java.lang.ClassLoader.defineClass(ClassLoader.java:620)
When I try to access my application via web browser, I get this exception which
doesn't tell me a whole lot:
(Trimmed out the application business exception chain)
| Caused by: java.lang.IllegalArgumentException
| at
sun.reflect.UnsafeStaticObjectFieldAccessorImpl.set(UnsafeStaticObjectFieldAccessorImpl.java:61)
| at java.lang.reflect.Field.set(Field.java:656)
| at org.jboss.aop.ClassAdvisor.initializeMethodChain(ClassAdvisor.java:461)
| at org.jboss.aop.ClassAdvisor.createInterceptorChains(ClassAdvisor.java:591)
| at org.jboss.aop.ClassAdvisor.access$300(ClassAdvisor.java:82)
| at org.jboss.aop.ClassAdvisor$1.run(ClassAdvisor.java:299)
| at java.security.AccessController.doPrivileged(Native Method)
| at org.jboss.aop.ClassAdvisor.attachClass(ClassAdvisor.java:271)
| at org.jboss.aop.AspectManager.initialiseClassAdvisor(AspectManager.java:590)
| at org.jboss.aop.AspectManager.getAdvisor(AspectManager.java:578)
| at com.mark.facade.EventManager.<clinit>(EventManager.java)
| ... 33 more
|
The weird thing is, I get this exception without even calling the method that the
interceptor is binded to.
Now, if I remove the one and only interceptor from the jboss-aop.xml, and deploy the app,
everything works fine. I put the interceptor back into the jboss-aop.xml file, I get the
exception stated above.
I'm pretty lost here and would appreciate any insight to this. Thank you in advance.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4012047#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...