Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-users] JBOSS, LTW and SDK1.4.2

This looks like a classloader issue. The aj.bat approach was meant mainly for standalone applications and hasn't worked well with app/web servers due to the classloading schemes they employ.

Can you try running the same server on Java 5 or 6 and pass it the -javaagent:/path/to/aspectjweaver.jar.

-Ramnivas

On Fri, Jul 10, 2009 at 10:32 AM, Johnson Lu <johnson.lu@optier.com> wrote:

Greetings:

 

I have been struggling to get JBOSS 4.0.5(on SDK1.4.2) to run with AspectJ, but thus far I have no success.

 

The run.bat startup in JBOSS\bin has been patched to conformed to what is in aj.bat (i.e setting the system class loader, and adding aj.class.path and aj.aspect.path as System parameters). If I don’t include run.jar in the classpath Jboss will always terminate with something like this: (run.jar is in –Daj.class.path):

 

Failed to boot JBoss:

java.lang.NullPointerException

        at org.jboss.Main.boot(Main.java:112)

        at org.jboss.Main$1.run(Main.java:490)

        at java.lang.Thread.run(Thread.java:534)

 

If I do put run.jar in the classpath, I get this:

 

java.lang.NoClassDefFoundError: org/jboss/mx/util/Serialization

        at javax.management.ObjectName.<clinit>(ObjectName.java:101)

        at org.jboss.mx.util.ObjectNameFactory.create(ObjectNameFactory.java:48)

        at org.jboss.system.server.ServerImpl.<clinit>(ServerImpl.java:82)

        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)

        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)

        at java.lang.reflect.Constructor.newInstance(Constructor.java:274)

        at java.lang.Class.newInstance0(Class.java:308)

        at java.lang.Class.newInstance(Class.java:261)

        at org.jboss.system.server.ServerLoader.createServer(ServerLoader.java:288)

        at org.jboss.system.server.ServerLoader.load(ServerLoader.java:267)

        at org.jboss.Main.boot(Main.java:194)

        at org.jboss.Main$1.run(Main.java:490)

        at java.lang.Thread.run(Thread.java:534)

Press any key to continue . . .

 

Can anyone shed some light, helpful hints on my plight? 

 

Thanks.

 

J.Lu

 


_______________________________________________
aspectj-users mailing list
aspectj-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/aspectj-users



Back to the top