I have two wsdl files and I need the path to be relative.
Mac Result:
File01Service.java excerpt:
wsdlLocation = "/service-api-definition/File01.wsdl"
File02Service.java excerpt:
wsdlLocation = "/service-api-definition/File02.wsdl"
PC Result:
File01Service.java excerpt:
wsdlLocation = "C:/Users/USERNAME/git/src/main/resources/service-api-definition/File01.wsdl
File02Service.java excerpt:
wsdlLocation = "C:/Users/USERNAME/git/src/main/resources/service-api-definition/File02.wsdl
Here is the excerpt from my pom.xml
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>jaxws-maven-plugin</artifactId>
<version>2.5</version>
<configuration>
<sourceDestDir>target/generated-sources/wsdlimport/Service1.0</sourceDestDir>
<wsdlDirectory>${basedir}/src/main/resources/service-api-definition/</wsdlDirectory>
<vmArgs>
<vmArg>-Djavax.xml.accessExternalSchema=all</vmArg>
</vmArgs>
<args>
<arg>-B-XautoNameResolution</arg>
</args>
<verbose>true</verbose>
</configuration>
<dependencies>
<dependency>
<groupId>org.jvnet.jaxb2_commons</groupId>
<artifactId>jaxb2-namespace-prefix</artifactId>
<version>1.3</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>wsdla-exec</id>
<goals>
<goal>wsimport</goal>
</goals>
<configuration>
<wsdlLocation>/service-api-definition/File01.wsdl</wsdlLocation>
</configuration>
</execution>
<execution>
<id>wsdlb-exec</id>
<goals>
<goal>wsimport</goal>
</goals>
<configuration>
<wsdlLocation>/service-api-definition/File02.wsdl</wsdlLocation>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>add-source</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>target/generated-sources/wsdlimport/Service1.0</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
I'm struggling to understand why the same project can produce two different results depending on platform. I need both machines to produce viable and identical jars. The mac is producing the correct result. Can someone help explain how the PC isn't doing this?
Thanks!