Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 4 of 4

Thread: java.lang.NoClassDefFoundError: javax/xml/ws/Service

  1. #1
    Junior Member
    Join Date
    Apr 2020
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default java.lang.NoClassDefFoundError: javax/xml/ws/Service

    running the script gives me this error, I already checked the manifest in the JAR file the classes are compiled (I don't know if they will be called at the time of the JVM) 5 days trying to solve the error, without success, can anyone help?

    2020-04-09 13:37:38.458: ElIntegrator: bca: Step142: Sendig BCA SetRequest for user 2053027
    2020-04-09 13:37:38.524: ElIntegrator: bca: Step143: Sendig BCA SetRequest for user 2054033
    2020-04-09 13:37:38.587: ElIntegrator: bca: Step144: Sendig BCA SetRequest for user 428476
    Exception in thread "main" java.lang.reflect.InvocationTargetException
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invo ke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invo ke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl. invoke(DelegatingMethodAccessorImpl.java:43)
    at java.base/java.lang.reflect.Method.invoke(Method.java:566)
    at org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoa der.main(JarRsrcLoader.java:61)
    Caused by: java.lang.NoClassDefFoundError: javax/xml/ws/Service
    at java.base/java.lang.ClassLoader.defineClass1(Native Method)
    at java.base/java.lang.ClassLoader.defineClass(ClassLoader.java :1016)
    at java.base/java.security.SecureClassLoader.defineClass(Secure ClassLoader.java:174)
    at java.base/java.net.URLClassLoader.defineClass(URLClassLoader .java:550)
    at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java: 458)
    at java.base/java.net.URLClassLoader$1.run(URLClassLoader.java: 452)
    at java.base/java.security.AccessController.doPrivileged(Native Method)
    at java.base/java.net.URLClassLoader.findClass(URLClassLoader.j ava:451)
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:5 88)
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:5 21)
    at pt.xxxx.it.yyyyy.elintegrator.APIBCA.sendSetValuat ionRequest(APIBCA.java:111)
    at pt.xxxx.it.yyyyy.elintegrator.BCA.bCASendRequest(B CA.java:144)
    at pt.xxxx.it.yyyyy.elintegrator.BCA.elBCA(BCA.java:1 57)
    at pt.xxxx.it.yyyyy.elintegrator.ElIntegrator.execute (ElIntegrator.java:444)
    at pt.xxxx.it.yyyyy.elintegrator.ElIntegrator.main(El Integrator.java:161)
    ... 5 more
    Caused by: java.lang.ClassNotFoundException: javax.xml.ws.Service
    at java.base/java.net.URLClassLoader.findClass(URLClassLoader.j ava:471)
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:5 88)
    at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:5 21)
    ... 20 more

    Java was updated from 8 to 11 (server side)
    Last edited by vytor; April 22nd, 2020 at 08:17 AM.

  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,162
    Thanks
    65
    Thanked 2,725 Times in 2,675 Posts

    Default Re: java.lang.NoClassDefFoundError: javax/xml/ws/Service

    What version of java are you using?
    What is on the command-line when you execute the code?
    If you don't understand my answer, don't ignore it, ask a question.

  3. #3
    Junior Member
    Join Date
    Apr 2020
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: java.lang.NoClassDefFoundError: javax/xml/ws/Service

    I receive the news(bad news) that the server was updated from Java 8 to 11...
    what should I do?

    --- Update ---

    If i execute the Jar file from my localhost (windows) there is no error (I think it ignore the classpath) but on the server there is the error that i post on top.

  4. #4
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,162
    Thanks
    65
    Thanked 2,725 Times in 2,675 Posts

    Default Re: java.lang.NoClassDefFoundError: javax/xml/ws/Service

    Did Oracle remove that class from Java 11?

    Take a look at this: https://blog.codefx.org/java/java-11-migration-guide/


    Also posted at: https://coderanch.com/t/729759/java/...rror-javax-xml
    If you don't understand my answer, don't ignore it, ask a question.

Similar Threads

  1. Replies: 2
    Last Post: July 2nd, 2013, 04:59 PM
  2. java.lang.NoClassDefFoundError help?
    By softballfrk13608 in forum Threads
    Replies: 2
    Last Post: March 6th, 2012, 03:22 PM
  3. java.lang.NoClassDefFoundError
    By nrao in forum What's Wrong With My Code?
    Replies: 1
    Last Post: January 27th, 2011, 08:18 AM
  4. java.lang.NoClassDefFoundError
    By anonymous001 in forum What's Wrong With My Code?
    Replies: 8
    Last Post: January 26th, 2011, 04:41 PM
  5. Replies: 3
    Last Post: May 15th, 2010, 02:05 PM

Tags for this Thread