java.lang.NoSuchMethodError: com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>([Ljava/lang/Class;Ljava/util/Collection;Ljava/util/Map;Ljava/lang/String;ZLcom/sun/xml/bind/v2/model/annotation/RuntimeAnnotationReader;ZZ)V

Stack Overflow | Sagar Dumboo | 5 months ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 1

    NoSuchMethodError while parsing xsd to generate classes using JAXB

    Stack Overflow | 5 months ago | Sagar Dumboo
    java.lang.NoSuchMethodError: com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>([Ljava/lang/Class;Ljava/util/Collection;Ljava/util/Map;Ljava/lang/String;ZLcom/sun/xml/bind/v2/model/annotation/RuntimeAnnotationReader;ZZ)V

    Root Cause Analysis

    1. java.lang.NoSuchMethodError

      com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>([Ljava/lang/Class;Ljava/util/Collection;Ljava/util/Map;Ljava/lang/String;ZLcom/sun/xml/bind/v2/model/annotation/RuntimeAnnotationReader;ZZ)V

      at com.sun.tools.xjc.reader.xmlschema.bindinfo.BindInfo.getJAXBContext()
    2. Old JAXB XJC
      NGCCRuntime.startElement
      1. com.sun.tools.xjc.reader.xmlschema.bindinfo.BindInfo.getJAXBContext(BindInfo.java:332)
      2. com.sun.tools.xjc.reader.xmlschema.bindinfo.AnnotationParserFactoryImpl$1.<init>(AnnotationParserFactoryImpl.java:80)
      3. com.sun.tools.xjc.reader.xmlschema.bindinfo.AnnotationParserFactoryImpl.create(AnnotationParserFactoryImpl.java:79)
      4. com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.createAnnotationParser(NGCCRuntimeEx.java:323)
      5. com.sun.xml.xsom.impl.parser.state.annotation.action0(annotation.java:48)
      6. com.sun.xml.xsom.impl.parser.state.annotation.enterElement(annotation.java:73)
      7. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      8. com.sun.xml.xsom.impl.parser.state.NGCCHandler.spawnChildFromEnterElement(NGCCHandler.java:74)
      9. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:500)
      10. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      11. com.sun.xml.xsom.impl.parser.state.NGCCHandler.revertToParentFromEnterElement(NGCCHandler.java:111)
      12. com.sun.xml.xsom.impl.parser.state.foreignAttributes.enterElement(foreignAttributes.java:50)
      13. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      14. com.sun.xml.xsom.impl.parser.state.NGCCHandler.spawnChildFromEnterElement(NGCCHandler.java:74)
      15. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:255)
      16. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      17. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:373)
      18. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      19. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:213)
      20. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      21. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:347)
      22. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      23. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:305)
      24. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.sendEnterElement(NGCCRuntime.java:378)
      25. com.sun.xml.xsom.impl.parser.state.complexType.enterElement(complexType.java:464)
      26. com.sun.xml.xsom.impl.parser.state.NGCCRuntime.startElement(NGCCRuntime.java:219)
      26 frames
    3. Java RT
      XMLFilterImpl.startElement
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      1 frame
    4. Old JAXB XJC
      ExtensionBindingChecker.startElement
      1. com.sun.tools.xjc.util.SubtreeCutter.startElement(SubtreeCutter.java:104)
      2. com.sun.tools.xjc.reader.ExtensionBindingChecker.startElement(ExtensionBindingChecker.java:144)
      2 frames
    5. Java RT
      XMLFilterImpl.startElement
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      1 frame
    6. Old JAXB XJC
      IncorrectNamespaceURIChecker.startElement
      1. com.sun.tools.xjc.reader.xmlschema.parser.IncorrectNamespaceURIChecker.startElement(IncorrectNamespaceURIChecker.java:113)
      1 frame
    7. Java RT
      XMLFilterImpl.startElement
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      1 frame
    8. Old JAXB XJC
      CustomizationContextChecker.startElement
      1. com.sun.tools.xjc.reader.xmlschema.parser.CustomizationContextChecker.startElement(CustomizationContextChecker.java:188)
      1 frame
    9. Java RT
      XMLFilterImpl.startElement
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      1 frame
    10. Old JAXB XJC
      ModelLoader$SpeculationChecker.startElement
      1. com.sun.tools.xjc.ModelLoader$SpeculationChecker.startElement(ModelLoader.java:455)
      1 frame
    11. Java RT
      XMLFilterImpl.startElement
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      1 frame
    12. Old JAXB XJC
      VersionChecker.startElement
      1. com.sun.tools.xjc.reader.internalizer.VersionChecker.startElement(VersionChecker.java:98)
      1 frame
    13. Java RT
      XMLFilterImpl.parse
      1. org.xml.sax.helpers.XMLFilterImpl.startElement(XMLFilterImpl.java:551)
      2. com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
      3. com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:380)
      4. com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2787)
      5. com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
      6. com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:118)
      7. com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
      8. com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
      9. com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
      10. com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
      11. com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
      12. com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:643)
      13. org.xml.sax.helpers.XMLFilterImpl.parse(XMLFilterImpl.java:357)
      13 frames
    14. Old JAXB XJC
      Driver$1.run
      1. com.sun.xml.xsom.parser.JAXPParser.parse(JAXPParser.java:79)
      2. com.sun.tools.xjc.ModelLoader$2.parse(ModelLoader.java:479)
      3. com.sun.tools.xjc.ModelLoader$XMLSchemaParser.parse(ModelLoader.java:262)
      4. com.sun.xml.xsom.impl.parser.NGCCRuntimeEx.parseEntity(NGCCRuntimeEx.java:301)
      5. com.sun.xml.xsom.impl.parser.ParserContext.parse(ParserContext.java:88)
      6. com.sun.xml.xsom.parser.XSOMParser.parse(XSOMParser.java:147)
      7. com.sun.tools.xjc.ModelLoader.createXSOMSpeculative(ModelLoader.java:496)
      8. com.sun.tools.xjc.ModelLoader.loadXMLSchema(ModelLoader.java:366)
      9. com.sun.tools.xjc.ModelLoader.load(ModelLoader.java:167)
      10. com.sun.tools.xjc.ModelLoader.load(ModelLoader.java:113)
      11. com.sun.tools.xjc.Driver.run(Driver.java:313)
      12. com.sun.tools.xjc.Driver.run(Driver.java:191)
      13. com.sun.tools.xjc.Driver._main(Driver.java:116)
      14. com.sun.tools.xjc.Driver.access$000(Driver.java:74)
      15. com.sun.tools.xjc.Driver$1.run(Driver.java:96)
      15 frames