A patch to be able to run JBoss 4.2.3 on JDK 1.7 or higher
If you have encoutered
java.lang.IllegalStateException: Cannot build JAXB context ... java.lang.StackTraceElement does not have a no-arg default constructor ...
on JBoss 4.2.3 when trying to run on a JDK 1.7 or higher, then this can help you.
Using a ZIP tool (Z-zip or else):
- Open the jar
jbossws-core.jar
located in thedeploy/jbossws.sar
folder of your server instance - Navigate (within the ZIP tool) to
org/jboss/ws/core/jaxws/
folder and replace theAbstractWrapperGenerator.class
class with the provided one, inside the jar (rememeber that a jar is a nothing but a zip file!) - Restart your server
- You may have also to place the following libraries within the JBoss
endorsed
folder
- jboss-saaj.jar
- jboss-jaxrpc.jar
- jboss-jaxws.jar
- jboss-jaxws-ext.jar
- jaxb-api.jar
- It it important to compile the
AbstractWrapperGenerator.java
with a Java 1.6 compliance level, otherwiser you will encounter problems of typejava.lang.UnsupportedClassVersionError