I solved it with a very bad action: i removed jaxen.jar from server/lib.
This is very weird... i know that my app can invoke the jdom methods but when it invoke the jaxen method it gave me the exception. I think this is because my app is using jaxen.jar from server/lib. The weird thing is that i can put jdom.jar in the server/lib and javaclassloadingcompliante true and false and the same problem occur. I also pus the jaxen and jdom in the server/default/lib (i´ve heard that server/lib is just for startup, don´t know if this is true) and removed in server/lib and the same problem persist. I also removed all these lib from my app to just use the jaxen and jdom from server/lib and/or server/default/lib and the problem persist. The only way i found is remove the jaxen.jar and force to use those in my app.
I´ve resolved my problem but i don´t like this way, it must be a solution more correct.
Sorry.. its not server/lib, is jbossXXX/lib.
If you have a sample application that demonstrates the problem create a bug report on http://jira.jboss.com/jira/browse/JBAS so I can look at it.
You will have to use scoped class loading and include both the jdom and jaxen jars in the application scope to override the jboss jars.
I was getting the above error.
I had jdom.jar in my jboss/server/all/lib directory and jaxen in jboss/lib directory. If I move the jaxen.jar from jboss/lib to jboss/server/all/lib directory, the problem gets fixed.
Thanks for the above info.
Continuation with my above response.....
The problem is in jboss4.0, it does not works other way round like moving jdom.jar to jboss/lib directory where jaxen.jar is available. The deployment of ejbs fails in my application which internally loads jdom classes
Now that I ahve moved jaxen.jar to server specific lib directory, it wont eb available for other servers. If anybody finds a better soln let me know