0
我有JAXWS-Maven的插件通過以下方式設置:JAXWS:WSGEN未能找到Web服務
<plugin>
<groupId>org.jvnet.jax-ws-commons</groupId>
<artifactId>jaxws-maven-plugin</artifactId>
<version>2.2</version>
<executions>
<execution>
<id>generate-wsdl-for-random-num-generator</id>
<goals>
<goal>wsgen</goal>
</goals>
<configuration>
<sei>mydomain.sib.RandomNumberGeneratorEndpoint</sei>
<destDir>${basedir}\wsdls\</destDir>
</configuration>
</execution>
</executions>
</plugin>
當我嘗試運行:
mvn jaxws:wsgen
我得到以下錯誤:
[ERROR] Failed to execute goal org.jvnet.jax-ws-commons:jaxws-maven-plugin:2.2:w
sgen (default-cli) on project soap-ws: No @javax.jws.WebService found. -> [Help
1]
的mydomain.sib.RandomNumberGeneratorEndpoint確實有@ javax.jws.WebService批註:
@WebService(endpointInterface = "mydomain.RandomNumberGenerator")
public class RandomNumberGeneratorEndpoint implements RandomNumberGenerator {
public double getRandomNumber(long limit) {
return Math.random() * limit;
}
}
有人知道我的設置有什麼問題嗎?
乾杯。