1

I'm making a Java Web Service project in Spring Tool Studio (Eclipse) to practice using SOAP and REST. I am unable to import any javax.jws packages.

I have tried refreshing the project and Maven Updating the project. I also checked my .m2 folder and found that there is no "jws" folder in my "javax" folder.

Its my understanding that these packages are supposed to be included standard in JDK installations, correct? I am doing this project with many other people, and I am the only one with this problem.

Here is an image of my project. Note how there are red import errors in MessageGen.java, however the project "SOAPGreeting" does not show a red project error.

Scrolling over the "javax.jws" error displays "The import javax.jws cannot be resolved" and suggests that I create my own class/interface/annotation/etc. Scrolling over the "@WebService" and "@WebMethod" errors display "WebService/WebMethod cannot be resolved as a type" and suggests I create my own annotation.

My JDK and JRE Versions:

java version "10.0.2" 2018-07-17

Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13)

Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode)

If anyone has any ideas on how I could fix this problem, please let me know! I appreciate any and all help! Thank you.

Brian
  • 135
  • 4
  • 16
  • Package [`javax.jws`](https://docs.oracle.com/javase/10/docs/api/javax/jws/package-summary.html) is in module `java.xml.ws` in Java 9+, and that module is not enabled by default. It has been removed entirely in Java 11. – Andreas Oct 12 '18 at 19:52

0 Answers0