NetBeans Forums
| View previous topic :: View next topic |
| Author |
Message |
waldyd
Joined: 24 Mar 2009 Posts: 8 Location: COLOMBIA
|
Posted: Wed Mar 25, 2009 10:58 pm Post subject: Netbeans 5.5 and JAX-WS 2.1/2.0 APIs |
|
|
Hello...
When Building a Project, the following was prompted by Netbeans 5.5:
build-impl.xml: You are running on JDK6 which comes with JAX-WS 2.0 API, but this tool requires JAX-WS 2.1 API. Use the endorsed standards override mechanism (http://java.sun.com/javase/6/docs/technotes/guides/standards/), or set xendorsed="true" on <wsimport>.
After googling i found something interesting: (at https://jax-ws.dev.java.net/guide/Using_JAX_WS_2_1_with_JavaSE6.html)
| Quote: |
2.8. Using JAX-WS 2.1 with JavaSE6
JavaSE6 ships with JAX-WS 2.0 API in rt.jar, which causes some trouble when you try to run applications that use JAX-WS 2.1 API. This document collects information about how to solve this issue.
2.8.1. Endorsed directory
One way to fix this is to copy jaxws-api.jar and jaxb-api.jar into JRE endorsed directory, which is $JAVA_HOME/lib/endorsed (or $JDK_HOME/jre/lib/endorsed)
Some application containers, such as Glassfish, modifies the location of the endorsed directory to a different place. From inside the JVM, you can check the current location by doing System.out.println(System.getProperty("java.endorsed.dirs"));
Obviously you still need other JAX-WS jars in your classpath.
Please do not put all the jars to the endorsed directory. This makes it impossible for JAX-WS RI to see other classes that it needs for its operation, such as servlet classes on the server-side, or Ant classes in the tool time. As those are not loaded by the bootstrap classloader, you'll get NoClassDefError on servlet/Ant classes. |
Then after doing the quoted above and setting xendorsed="true" on <wsimport>. Netbeans 5.5 prompted the following:
build-impl.xml: java.lang.ClassNotFoundException: There's no JAX-WS 2.1 API in the classpath
Any ideas to solve this issue? |
|
| Back to top |
|
 |
waldyd
Joined: 24 Mar 2009 Posts: 8 Location: COLOMBIA
|
Posted: Thu Mar 26, 2009 3:07 pm Post subject: Netbeans 5.5 & JAX-WS 2.1 API |
|
|
Hello...
After copying the JAX-WS 2.1 API implementation packages (jaxws-api.jar and jaxb-api.jar) into the java system endorsed folder (C:\Archivos de programa\Java\jdk1.6.0\jre\lib\endorsed) and setting xendorsed="true" on <wsimport> in build-impl.xml file and finally restarting the IDE (it may need to restart the PC also), the problem disappeared...
Best Regards,
Nestor Waldyd |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You can attach files in this forum You can download files in this forum
|
|