943,101 Members | Top Members by Rank

Ad:
  • JSP Discussion Thread
  • Unsolved
  • Views: 1977
  • JSP RSS
Jul 31st, 2010
0

j2ee tutorial examples helloservice

Expand Post »
Hi,

I was trying to j2ee web service example helloservice. When I was building the simpleclient I got the error:

JSP Syntax (Toggle Plain Text)
  1. wsimport-client-generate-nosecure:
  2.  
  3. wsimport-client-generate-nojvmargs:
  4. [echo] C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\bp-project\ma
  5. in.xml/../../../../../../glassfish/lib/endorsed
  6. [echo] helloservice.endpoint
  7. [echo] build/generated/wsimport/client
  8. [echo] build/jar
  9. [echo] http://localhost:8080/helloservice/HelloService?WSDL
  10. [wsimport] Consider using <depends>/<produces> so that wsimport won't do unnece
  11. ssary compilation
  12. [wsimport] JDK's tools.jar was not found in C:\Program Files\Java\lib\tools.jar
  13. . Usually this means you are running JRE, not JDK. Please use the java command i
  14. n JDK 5.0 or later (not JRE.)
  15. [wsimport] Command invoked: wsimport "C:\Program Files\Java\jre6\bin\java.exe"
  16. -Djava.endorsed.dirs=C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\bp-p
  17. roject\main.xml/../../../../../../glassfish/lib/endorsed -classpath C:\glassfish
  18. v3\glassfish\modules\acc-config.jar; ... C:\glassfishv3\glassfish\modules\weld-integration.jar;C:\glassfishv3\glassfish\modules\weld-osgi-bundle.jar com.sun.tools.ws.WsImport -d C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\jaxws\simpleclient\build\jar -Xendorsed -keep -s C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\jaxws\simpleclient\build\generated\wsimport\client http://localhost:8080/helloservice/HelloService?WSDL -p helloservice.endpoint
  19.  
  20. BUILD FAILED
  21. C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\bp-project\jaxws-ant.xml:
  22. 27: The following error occurred while executing this line:
  23. C:\glassfishv3\glassfish\docs\javaee-tutorial\examples\bp-project\jaxws-ant.xml:
  24. 42: wsimport failed

The generating code is:

JSP Syntax (Toggle Plain Text)
  1. <target name="wsimport-client-generate-nosecure" unless="wsimport.secure">
  2. <antcall target="wsimport-client-generate-nojvmargs"/>
  3. </target>
  4.  
  5. <target name="wsimport-client-generate-nojvmargs">
  6. <echo message="${jaxws.endorseddir.prefix}/lib/endorsed"/>
  7. <echo message="${wsimport.package}"/>
  8. <echo message="${build.generated.dir}/wsimport/client"/>
  9. <echo message="${build.classes.dir}"/>
  10. <echo message="${wsimport.wsdl.location}"/>
  11. <wsimport sourcedestdir="${build.generated.dir}/wsimport/client"
  12. package="${wsimport.package}"
  13. destdir="${build.classes.dir}"
  14. wsdl="${wsimport.wsdl.location}"
  15. verbose="${verbose}"
  16. fork="true"
  17. xendorsed="true">
  18. <jvmarg line="-Djava.endorsed.dirs=${jaxws.endorseddir.prefix}/lib/endorsed"/>
  19. </wsimport>
  20. </target>

I don't know why I am getting this stupid mistake. I didn't modify anything. I just ran the ant command inside the simpleclient directory. Before that I ran the ant all command inside helloservice directory. So I am not sure how to deal with that. Please offer some help here.

Thanks.
Similar Threads
Reputation Points: 11
Solved Threads: 0
Posting Whiz in Training
johndoe444 is offline Offline
214 posts
since Feb 2008
Jul 31st, 2010
0
Re: j2ee tutorial examples helloservice
Forget it. Because of that jerk who wrote this in the jaxws-ant.xml:

xml Syntax (Toggle Plain Text)
  1. <taskdef name="wsimport" classname="com.sun.tools.ws.ant.WsImport" onerror="ignore">
  2. <classpath path="${java.home}/../lib/tools.jar:${javac.classpath}"/>
  3. <classpath refid="javaee.classpath"/>
  4. </taskdef>
Last edited by peter_budo; Jul 31st, 2010 at 5:11 am. Reason: Keep It Organized - For easy readability, always wrap programming code within posts in [code] (code blocks)
Reputation Points: 11
Solved Threads: 0
Posting Whiz in Training
johndoe444 is offline Offline
214 posts
since Feb 2008
Jul 31st, 2010
0
Re: j2ee tutorial examples helloservice
If it is solved, then please mark it as solved.
Moderator
Featured Poster
Reputation Points: 2786
Solved Threads: 871
Code tags enforcer
peter_budo is offline Offline
6,649 posts
since Dec 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in JSP Forum Timeline: JSPs, Eclipse and Crystal Reports 2008
Next Thread in JSP Forum Timeline: How to get the current date in JAVA





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC