[JBoss AOP] - Not quite getting it (aka noclassdeffound)
by chip_schoch
I am new to AOP and have been attempting to get a basic trace advice running. I am using jdk 5.0 and annotations, JBossAS 4.0.5. I created my class and annotated a method but nothing happened. I suspected that I needed to set 'EnableLoadtimeWeaving' to true because I did not use any aopc.
Is that a correct understanding of how it works?
I set the flag to true and then I got a null pointer exception. See trace 1.
I then downloaded 1.5.4 SP2 TWICE but it would not unzip, so I downloaded 1.5.4 SP1 and used the jboss-aop-jdk50.deployer from that. I then got a noclassdeferror for AOPScopedClassLoaderHelper. See trace 0.
I searched for a jar with that class but could not find one so I am pretty much dead in the water. Any help would really be appreciated.
Thanks
TRACE 0.
Caused by: java.lang.NoClassDefFoundError: org/jboss/aop/classpool/AOPScopedClassLoaderHelper
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2357)
at java.lang.Class.getConstructor0(Class.java:2671)
at java.lang.Class.getConstructor(Class.java:1629)
at org.jboss.mx.server.MBeanServerImpl.instantiate(MBeanServerImpl.java:1232)
at org.jboss.mx.server.MBeanServerImpl.instantiate(MBeanServerImpl.java:286)
at org.jboss.mx.server.MBeanServerImpl.createMBean(MBeanServerImpl.java:344)
at org.jboss.system.ServiceCreator.install(ServiceCreator.java:157)
... 35 more
TRACE 1.
java.lang.NullPointerException
at org.jboss.aop.deployment.AspectManagerServiceJDK5.attachTranslator(AspectManagerServiceJDK5.java:42)
at org.jboss.aop.deployment.AspectManagerService.createService(AspectManagerService.java:121)
at org.jboss.system.ServiceMBeanSupport.jbossInternalCreate(ServiceMBeanSupport.java:260)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:243)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.create(Unknown Source)
at org.jboss.system.ServiceController.create(ServiceController.java:330)
at org.jboss.system.ServiceController.create(ServiceController.java:273)
at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy4.create(Unknown Source)
at org.jboss.deployment.SARDeployer.create(SARDeployer.java:258)
at org.jboss.deployment.MainDeployer.create(MainDeployer.java:969)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:818)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy6.deploy(Unknown Source)
at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:610)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:274)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:225)
2007-03-03 18:03:55,953 WARN [org.jboss.system.ServiceController] Problem creating service jboss.aop:service=AspectManager
java.lang.NullPointerException
at org.jboss.aop.deployment.AspectManagerServiceJDK5.attachTranslator(AspectManagerServiceJDK5.java:42)
at org.jboss.aop.deployment.AspectManagerService.createService(AspectManagerService.java:121)
at org.jboss.system.ServiceMBeanSupport.jbossInternalCreate(ServiceMBeanSupport.java:260)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:243)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
at $Proxy0.create(Unknown Source)
at org.jboss.system.ServiceController.create(ServiceController.java:330)
at org.jboss.system.ServiceController.create(ServiceController.java:273)
at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy4.create(Unknown Source)
at org.jboss.deployment.SARDeployer.create(SARDeployer.java:258)
at org.jboss.deployment.MainDeployer.create(MainDeployer.java:969)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:818)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy6.deploy(Unknown Source)
at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:610)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:274)
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4024885#4024885
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4024885
19Â years, 1Â month
[JBoss Seam] - How to trigger a new Entity Instance with Home Object in sea
by sjmenden
I used seam gen to generate my entities for CRUD operations and it appears to work great at first. However, there is an inheirent problem. On the List page for my entity, I can create my entity one time and everything works great. The next time I go to create another entity, the previous one must still be resident becuase I get a duplicate identifier error from Hibernate, because it is attempting to persist the same entity.
This is default behavior with the seam generated CRUD app, and I am wondering how to get around it, I know the answer, I just don't know where to put the code. I know that when clicking on the Create Entity, I should somehow trigger a new instance of the Entity in the Home object to be created.
What confuses me is the done button has a propogation="end" on it, which I assumed would end the conversation and a new one would be created, thus, a new reference to my entityHome object, but that is not the case, there is still the reference to the old one.
Thanks for the help.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4024877#4024877
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4024877
19Â years, 1Â month
[EJB 3.0] - Embed EJB3 into my own application (try and errors)
by marcelruff
Hi,
i'm clicking/trying since several days to create some
few EJB3 beans.
I would like to have them as plain JDK 1.5 Java beans with some annotations to persist them with hibernate to postgres without any dependency on microkernels and such.
I would expect to use some few *.jar files for the annotations, hibernate and postgres JDBC and throw them into my application to easily access the DB.
I think i have followed all wikis, tutorials around but i
always get stuck (jboss-EJB-3.0_Embeddable_ALPHA_5.zip,
jboss-EJB-3.0_RC9_Patch_1.zip).
With the ejb3-project-backup.zip and a lot of copying i got a bit further, but running the TestNGDummyTest i get:
"Cannot find embedded-ejb3-project-ds-beans.xml"
What is a proper/easy way to get started,
is it a naive approach i follow or the wrong tools?
Thanks for some psychological assistance,
Marcel
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4024876#4024876
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4024876
19Â years, 1Â month