I’m currently updating a JAX RS application (that uses CXF and Spring) to run on JBoss instead of tomcat.
It deploys on Tomcat ok but when I attempt to deploy to JBoss I get this error from aspectj “warning no match for this type name”. The class it claims does not exist is being used for a point cut, declared within the spring xml config. The class itself is defiantly compiled within the WAR.
I’m guessing that this is a class loader issue, but don’t know enough about JBoss to figure it out.
Can someone suggest why this might be happening and a solution for it?
This was a class loading issue, but not the one I though. One of classes being woven is a datasource. I was using Jboss data sources for the Jboss version of the WAR, so the data source was org.jboss.jca.adapters.jdbc.WrapperDataSource when on Jboss but on tomcat was org.apache.commons.dbcp.BasicDataSource.
As a result, during the weaving process aspectJ was failing to load the jboss class. Adding
solved the problem.
There’s a post on the Spring forum that mentions this: http://forum.springsource.org/showthread.php?113581-Spring-JBoss7-aop-problems-to-get-datasource