繁体   English   中英

成功构建但找不到wsdl文件?

[英]successfully building but the wsdl file not found?

我尝试使用jaxws maven插件finaly生成wsdl文件:“成功构建”,但是我的wsdl文件未生成,在\\ target \\ surefire-reports文件夹中很正常,但是构建后没有

SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building BSCSwebservices Maven Webapp 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for com.sun.xml.stream.buffer:streambuffer:jar:0.4 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
 [WARNING] The POM for org.jvnet.staxex:stax-ex:jar:1.0 is invalid, transitive dependencies (if any) will not be available, enable debug logging for more details
[INFO] 
[INFO] --- maven-resources-plugin:2.5:resources (default-resources) @ BSCSwebservices ---
[debug] execute contextualize
[WARNING] File encoding has not been set, using platform encoding Cp1252, i.e. build is platform dependent!
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] Copying 6 resources
[INFO] 
[INFO] --- maven-compiler-plugin:2.3.2:compile (default-compile) @ BSCSwebservices ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-resources-plugin:2.5:testResources (default-testResources) @ BSCSwebservices ---
[debug] execute contextualize
[WARNING] Using platform encoding (Cp1252 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory C:\Users\sayed\workspace\BSCSwebservices\src\test\resources
[INFO] 
[INFO] --- maven-compiler-plugin:2.3.2:testCompile (default-testCompile) @ BSCSwebservices ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- maven-surefire-plugin:2.10:test (default-test) @ BSCSwebservices ---
[INFO] Surefire report directory: C:\Users\sayed\workspace\BSCSwebservices\target\surefire-reports

T E S T S

Results :

Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 
[INFO] --- maven-war-plugin:2.1.1:war (default-war) @ BSCSwebservices ---
[INFO] Packaging webapp
[INFO] Assembling webapp [BSCSwebservices] in [C:\Users\sayed\workspace\BSCSwebservices\target\BSCSwebservices]
[INFO] Processing war project
[INFO] Copying webapp resources [C:\Users\sayed\workspace\BSCSwebservices\src\main\webapp]
[INFO] Webapp assembled in [1042 msecs]
[INFO] Building war: C:\Users\sayed\workspace\BSCSwebservices\target\BSCSwebservices.war
[WARNING] Warning: selected war files include a WEB-INF/web.xml which will be ignored 
(webxml attribute is missing from war task, or ignoreWebxml attribute is specified as 'true')
[INFO] 
[INFO] --- jaxws-maven-plugin:1.11:wsgen (default) @ BSCSwebservices ---

warning: The apt tool and its associated API are planned to be
removed in the next major JDK release.  These features have been
superseded by javac and the standardized annotation processing API,
javax.annotation.processing and javax.lang.model.  Users are
recommended to migrate to the annotation processing features of
javac; see the javac man page for more information.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:30.437s
[INFO] Finished at: Fri Aug 02 23:00:03 WAT 2013
[INFO] Final Memory: 16M/40M
[INFO] ------------------------------------------------------------------------

这是pom.xml的一部分

<plugins>
    <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>jaxws-maven-plugin</artifactId>
        <version>1.11</version>
        <executions>
                <execution>
                <configuration>
                <sei>com.ws.BillingAccountRead</sei>
                <genwsdl>true</genwsdl>  
                 <keep>true</keep>

        </configuration>
                <phase>package</phase>      
                        <goals>
                        <goal>wsgen</goal>
                        </goals>


                </execution>

        </executions>


    </plugin>
    </plugins>
    </build>
  </project>

当我使用mvn clean package -X

<configuration>
 <destDir default-value="${project.build.outputDirectory}"/>
 <extension default-value="false"/>
 <genWsdl default-value="false"/>
 <keep default-value="false">true</keep>
 <pluginArtifactMap>${plugin.artifactMap}</pluginArtifactMap>
 <pluginArtifacts>${plugin.artifacts}</pluginArtifacts>
 <project>${project}</project>
 <resourceDestDir default-value="${project.build.directory}/jaxws/wsgen/wsdl"/>

 <sei>com.ws.BillingAccountRead</sei>
 <verbose default-value="false">true</verbose>
</configuration>

我认为您可能希望在“生成源”阶段或“生成资源”而不是“包”阶段构建wsdl。

它应该在${resourceDestDir}生成wsdl,如下所示,使用verbose = true进行配置 ,并使用-X标志执行mvn命令,然后仔细查看maven日志。

<executions>
                <execution>
                <configuration>
                <sei>com.ws.BillingAccountRead</sei>
                <genwsdl>true</genwsdl>  
                 <keep>true</keep>
                <verbose>true</verbose>
        </configuration>
                <phase>package</phase>      
                        <goals>
                        <goal>wsgen</goal>
                        </goals>


                </execution>

        </executions>

尝试使用-X或-e进行构建以从日志中获取更多信息

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM