Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception - java.lang.ClassNotFoundException: org.codehaus.mojo.jaxws.Invoker #90

Open
lahirujayathilake opened this issue Nov 3, 2020 · 1 comment

Comments

@lahirujayathilake
Copy link

I am using org.codehaus.mojo:jaxws-maven-plugin:2.6 to generate stub code using a WSDL and I am getting the error

[INFO] jaxws:wsimport args: [-keep, -s, 'C:\<path>\target\generated-sources\common\java', -d, 'C:\<path>\target\classes', -encoding, UTF-8, -extension, -Xnocompile, -XadditionalHeaders, -B-Xinheritance, -b, 'file:/C:/<path>/bindings.xml', "file:/C:/<path>/FiskalizacijaService.wsdl"] Error: Could not find or load main class org.codehaus.mojo.jaxws.Invoker Caused by: java.lang.ClassNotFoundException: org.codehaus.mojo.jaxws.Invoker

Maven plugin looks like

<plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>jaxws-maven-plugin</artifactId> <version>2.6</version> <dependencies> <dependency> <groupId>org.jvnet.jaxb2_commons</groupId> <artifactId>jaxb2-basics</artifactId> <version>0.6.4</version> </dependency> </dependencies> <executions> <execution> <!-- another execution --> </execution> <execution> <id>add-source</id> <goals> <goal>wsimport</goal> </goals> <configuration> <xjcArgs> <xjcArg>-Xinheritance</xjcArg> </xjcArgs> <bindingFiles> <bindingFile>${basedir}/resources/schema/bindings.xml</bindingFile> </bindingFiles> <vmArgs> <vmArg>-Djavax.xml.accessExternalSchema=all</vmArg> </vmArgs> <extension>true</extension> <wsdlFiles> <wsdlFile>${basedir}/resources/schema/Service.wsdl</wsdlFile> </wsdlFiles> <keep>true</keep> <xadditionalHeaders>true</xadditionalHeaders> <sourceDestDir>${project.build.directory}/generated-sources/common/java</sourceDestDir> </configuration> </execution> </executions> </plugin>

This works in JDK 8 but doesn't work with the JDK9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants