IBM Support

PI67526: JAXRS 1.1 AND 2.0 CLIENTS DO NOT CONTAIN JAVAX.ANNOTATION.* CLASSES AS EXPECTED

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • JAXRS 1.1 and 2.0 clients do not contain javax.annotation.*
    classes as expected.  As a result, ClassNotFoundException such
    as the following may occur:
    
    Exception in thread "main" java.lang.NoClassDefFoundError:
    javax/annotation/Priority
            at
    org.apache.cxf.jaxrs.utils.AnnotationUtils.getBindingPriority(An
    notationUtils.java:85)
            at
    org.apache.cxf.jaxrs.impl.ConfigurableImpl.register(Configurable
    Impl.java:69)
            at
    org.apache.cxf.jaxrs.client.spec.ClientImpl.register(ClientImpl.
    java:172)
            at
    org.apache.cxf.jaxrs.client.spec.ClientImpl.register(ClientImpl.
    java:49)
            at Test.main(Test.java:15)
    Caused by: java.lang.ClassNotFoundException:
    javax.annotation.Priority
            at
    java.net.URLClassLoader.findClass(URLClassLoader.java:381)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
            at
    sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
            ... 5 more
    

Local fix

  • Add endorsed/endorsed_apis_9.0.jar to the classpath.
    

Problem summary

  • ****************************************************************
    * USERS AFFECTED:  All users of IBM WebSphere Application      *
    *                  Server JAX-RS thin client jars              *
    ****************************************************************
    * PROBLEM DESCRIPTION: A J2SE application that uses one        *
    *                      of the JAX-RS thin client jars          *
    *                      fails with ClassNotFoundException:      *
    *                      javax.annotation.Priority               *
    ****************************************************************
    * RECOMMENDATION:                                              *
    ****************************************************************
    A J2SE application that uses one of the JAX-RS thin client jars
    fails with ClassNotFoundException: javax.annotation.Priority
    This is due to missing classes.
    

Problem conclusion

Temporary fix

  • Add runtimes\endorsed\endorsed_apis_9.0.jar to the classpath.
    

Comments

APAR Information

  • APAR number

    PI67526

  • Reported component name

    WEBSPHERE APP S

  • Reported component ID

    5724J0800

  • Reported release

    900

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt / Xsystem

  • Submitted date

    2016-08-12

  • Closed date

    2016-11-11

  • Last modified date

    2016-11-11

  • APAR is sysrouted FROM one or more of the following:

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    WEBSPHERE APP S

  • Fixed component ID

    5724J0800

Applicable component levels

  • R900 PSY

       UP

[{"Business Unit":{"code":"BU053","label":"Cloud \u0026 Data Platform"},"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"900","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
14 October 2021