Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-14746

Error class com.sun.xml.bind.v2.model.annotation.AnnotationReader not found on Java 9

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 9.8
    • Fix Version/s: 9.9-rc-2
    • Component/s: Dependency Upgrades
    • Labels:
    • Environment:
      Java 9
    • Difficulty:
      Unknown
    • Documentation:
      N/A
    • Documentation in Release Notes:
      N/A
    • Similar issues:

      Description

      Found by Ilie Andriuta.

      Getting the following error at startup:

      2017-09-28 11:54:23,488 [main] ERROR aultExtensionRepositoryManager - Failed to add repository [extensions.xwiki.org:xwiki:http://extensions.xwiki.org/xwiki/rest/] org.xwiki.extension.repository.ExtensionRepositoryException: Unsupported repository type [xwiki]
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.addRepository(DefaultExtensionRepositoryManager.java:201)
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.initialize(DefaultExtensionRepositoryManager.java:150)
       at org.xwiki.component.embed.InitializableLifecycleHandler.handle(InitializableLifecycleHandler.java:39)
       at org.xwiki.component.embed.EmbeddableComponentManager.createInstance(EmbeddableComponentManager.java:322)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:424)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:392)
       at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:190)
       at org.xwiki.component.embed.GenericProvider.getInstance(GenericProvider.java:111)
       at org.xwiki.component.embed.GenericProvider.get(GenericProvider.java:100)
       at org.xwiki.extension.internal.ExtensionApplicationStartedListener.onEvent(ExtensionApplicationStartedListener.java:97)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:304)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:269)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:321)
       at org.xwiki.container.servlet.XWikiServletContextListener.contextInitialized(XWikiServletContextListener.java:126)
       at org.eclipse.jetty.server.handler.ContextHandler.callContextInitialized(ContextHandler.java:890)
       at org.eclipse.jetty.servlet.ServletContextHandler.callContextInitialized(ServletContextHandler.java:532)
       at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:853)
       at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:344)
       at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1501)
       at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1463)
       at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:785)
       at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:261)
       at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:545)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:41)
       at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:188)
       at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:502)
       at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:150)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:180)
       at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:453)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:64)
       at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:610)
       at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:529)
       at org.eclipse.jetty.util.Scanner.scan(Scanner.java:392)
       at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:313)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:150)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:564)
       at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:239)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:131)
       at org.eclipse.jetty.server.Server.start(Server.java:452)
       at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:113)
       at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113)
       at org.eclipse.jetty.server.Server.doStart(Server.java:419)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1515)
       at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1439)
       at java.base/java.security.AccessController.doPrivileged(Native Method)
       at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1438)
       at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
       at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
       at java.base/java.lang.reflect.Method.invoke(Unknown Source)
       at org.eclipse.jetty.start.Main.invokeMain(Main.java:221)
       at org.eclipse.jetty.start.Main.start(Main.java:506)
       at org.eclipse.jetty.start.Main.main(Main.java:78)
      Caused by: org.xwiki.component.manager.ComponentLookupException: Failed to lookup component [org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepositoryFactory] identified by [role = [interface org.xwiki.extension.repository.ExtensionRepositoryFactory] hint = [xwiki]]
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:394)
       at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:190)
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.addRepository(DefaultExtensionRepositoryManager.java:194)
       ... 57 common frames omitted
      Caused by: java.lang.NoClassDefFoundError: com/sun/xml/bind/v2/model/annotation/AnnotationReader
       at java.base/java.lang.ClassLoader.defineClass1(Native Method)
       at java.base/java.lang.ClassLoader.defineClass(Unknown Source)
       at java.base/java.security.SecureClassLoader.defineClass(Unknown Source)
       at java.base/java.net.URLClassLoader.defineClass(Unknown Source)
       at java.base/java.net.URLClassLoader.access$100(Unknown Source)
       at java.base/java.net.URLClassLoader$1.run(Unknown Source)
       at java.base/java.net.URLClassLoader$1.run(Unknown Source)
       at java.base/java.security.AccessController.doPrivileged(Native Method)
       at java.base/java.net.URLClassLoader.findClass(Unknown Source)
       at org.eclipse.jetty.webapp.WebAppClassLoader.foundClass(WebAppClassLoader.java:644)
       at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:550)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
       at java.base/java.lang.Class.privateGetDeclaredMethods(Unknown Source)
       at java.base/java.lang.Class.getMethodsRecursive(Unknown Source)
       at java.base/java.lang.Class.getMethod0(Unknown Source)
       at java.base/java.lang.Class.getMethod(Unknown Source)
       at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:214)
       at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:175)
       at javax.xml.bind.ContextFinder.find(ContextFinder.java:353)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:508)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:465)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:366)
       at org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepositoryFactory.initialize(XWikiExtensionRepositoryFactory.java:65)
       at org.xwiki.component.embed.InitializableLifecycleHandler.handle(InitializableLifecycleHandler.java:39)
       at org.xwiki.component.embed.EmbeddableComponentManager.createInstance(EmbeddableComponentManager.java:322)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:424)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:392)
       ... 59 common frames omitted
      Caused by: java.lang.ClassNotFoundException: com.sun.xml.bind.v2.model.annotation.AnnotationReader
       at java.base/java.net.URLClassLoader.findClass(Unknown Source)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:560)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       ... 87 common frames omitted
      
      2017-09-28 11:54:23,493 [main] ERROR aultExtensionRepositoryManager - Failed to add repository [store.xwiki.com:xwiki:https://store.xwiki.com/xwiki/rest/] org.xwiki.extension.repository.ExtensionRepositoryException: Unsupported repository type [xwiki]
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.addRepository(DefaultExtensionRepositoryManager.java:201)
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.initialize(DefaultExtensionRepositoryManager.java:150)
       at org.xwiki.component.embed.InitializableLifecycleHandler.handle(InitializableLifecycleHandler.java:39)
       at org.xwiki.component.embed.EmbeddableComponentManager.createInstance(EmbeddableComponentManager.java:322)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:424)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:392)
       at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:190)
       at org.xwiki.component.embed.GenericProvider.getInstance(GenericProvider.java:111)
       at org.xwiki.component.embed.GenericProvider.get(GenericProvider.java:100)
       at org.xwiki.extension.internal.ExtensionApplicationStartedListener.onEvent(ExtensionApplicationStartedListener.java:97)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:304)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:269)
       at org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:321)
       at org.xwiki.container.servlet.XWikiServletContextListener.contextInitialized(XWikiServletContextListener.java:126)
       at org.eclipse.jetty.server.handler.ContextHandler.callContextInitialized(ContextHandler.java:890)
       at org.eclipse.jetty.servlet.ServletContextHandler.callContextInitialized(ServletContextHandler.java:532)
       at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:853)
       at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:344)
       at org.eclipse.jetty.webapp.WebAppContext.startWebapp(WebAppContext.java:1501)
       at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1463)
       at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:785)
       at org.eclipse.jetty.servlet.ServletContextHandler.doStart(ServletContextHandler.java:261)
       at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:545)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:41)
       at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:188)
       at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:502)
       at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:150)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:180)
       at org.eclipse.jetty.deploy.providers.WebAppProvider.fileAdded(WebAppProvider.java:453)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:64)
       at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:610)
       at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:529)
       at org.eclipse.jetty.util.Scanner.scan(Scanner.java:392)
       at org.eclipse.jetty.util.Scanner.doStart(Scanner.java:313)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:150)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:564)
       at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:239)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:131)
       at org.eclipse.jetty.server.Server.start(Server.java:452)
       at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:113)
       at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:113)
       at org.eclipse.jetty.server.Server.doStart(Server.java:419)
       at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:68)
       at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1515)
       at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1439)
       at java.base/java.security.AccessController.doPrivileged(Native Method)
       at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:1438)
       at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
       at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
       at java.base/java.lang.reflect.Method.invoke(Unknown Source)
       at org.eclipse.jetty.start.Main.invokeMain(Main.java:221)
       at org.eclipse.jetty.start.Main.start(Main.java:506)
       at org.eclipse.jetty.start.Main.main(Main.java:78)
      Caused by: org.xwiki.component.manager.ComponentLookupException: Failed to lookup component [org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepositoryFactory] identified by [role = [interface org.xwiki.extension.repository.ExtensionRepositoryFactory] hint = [xwiki]]
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:394)
       at org.xwiki.component.embed.EmbeddableComponentManager.getInstance(EmbeddableComponentManager.java:190)
       at org.xwiki.extension.repository.internal.DefaultExtensionRepositoryManager.addRepository(DefaultExtensionRepositoryManager.java:194)
       ... 57 common frames omitted
      Caused by: java.lang.NoClassDefFoundError: com/sun/xml/bind/v2/model/annotation/AnnotationReader
       at java.base/java.lang.ClassLoader.defineClass1(Native Method)
       at java.base/java.lang.ClassLoader.defineClass(Unknown Source)
       at java.base/java.security.SecureClassLoader.defineClass(Unknown Source)
       at java.base/java.net.URLClassLoader.defineClass(Unknown Source)
       at java.base/java.net.URLClassLoader.access$100(Unknown Source)
       at java.base/java.net.URLClassLoader$1.run(Unknown Source)
       at java.base/java.net.URLClassLoader$1.run(Unknown Source)
       at java.base/java.security.AccessController.doPrivileged(Native Method)
       at java.base/java.net.URLClassLoader.findClass(Unknown Source)
       at org.eclipse.jetty.webapp.WebAppClassLoader.foundClass(WebAppClassLoader.java:644)
       at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:550)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
       at java.base/java.lang.Class.privateGetDeclaredMethods(Unknown Source)
       at java.base/java.lang.Class.getMethodsRecursive(Unknown Source)
       at java.base/java.lang.Class.getMethod0(Unknown Source)
       at java.base/java.lang.Class.getMethod(Unknown Source)
       at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:214)
       at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:175)
       at javax.xml.bind.ContextFinder.find(ContextFinder.java:353)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:508)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:465)
       at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:366)
       at org.xwiki.extension.repository.xwiki.internal.XWikiExtensionRepositoryFactory.initialize(XWikiExtensionRepositoryFactory.java:65)
       at org.xwiki.component.embed.InitializableLifecycleHandler.handle(InitializableLifecycleHandler.java:39)
       at org.xwiki.component.embed.EmbeddableComponentManager.createInstance(EmbeddableComponentManager.java:322)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:424)
       at org.xwiki.component.embed.EmbeddableComponentManager.getComponentInstance(EmbeddableComponentManager.java:392)
       ... 59 common frames omitted
      Caused by: java.lang.ClassNotFoundException: com.sun.xml.bind.v2.model.annotation.AnnotationReader
       at java.base/java.net.URLClassLoader.findClass(Unknown Source)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:560)
       at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
       ... 87 common frames omitted 
      

        Attachments

          Activity

            People

            • Assignee:
              tmortagne Thomas Mortagne
              Reporter:
              tmortagne Thomas Mortagne
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: