Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/371.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在axis2-java2wsdl-maven-plugin中指定地址位置?_Java_Maven_Wsdl_Axis2 - Fatal编程技术网

如何在axis2-java2wsdl-maven-plugin中指定地址位置?

如何在axis2-java2wsdl-maven-plugin中指定地址位置?,java,maven,wsdl,axis2,Java,Maven,Wsdl,Axis2,我使用java calss axis2-java2wsdl-maven-plugin生成wsdl。下面我引用了一段pom.xml: <plugin> <groupId>org.apache.axis2</groupId> <artifactId>axis2-java2wsdl-maven-plugin</artifactId> <ver

我使用java calss axis2-java2wsdl-maven-plugin生成wsdl。下面我引用了一段pom.xml:

<plugin>
                <groupId>org.apache.axis2</groupId>
                <artifactId>axis2-java2wsdl-maven-plugin</artifactId>
                <version>1.6.2</version>
                <configuration>
                    <className>Path_to_ws_class</className>
                <outputFileName>src/main/webapp/webservice.wsdl</outputFileName>
        <schemaTargetNamespace>http://test.test/xsd</schemaTargetNamespace>
                    <wsdlVersion>${project.version}</wsdlVersion>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>java2wsdl</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

org.apache.axis2
axis2-java2wsdl-maven-plugin
1.6.2
路径到类
src/main/webapp/webservice.wsdl
http://test.test/xsd
${project.version}
java2wsdl
但它会在wsdl文件的底部生成:

<wsdl:port name="WebServiceHttpSoap11Endpoint" binding="axis2:WebServiceSoap11Binding">
<soap:address location="http://localhost:8080/axis2/services/MerchantWebService"/>
</wsdl:port>

我不需要以下部分,因为我的web服务无法通过此链接使用:

<soap:address location="http://localhost:8080/axis2/services/MerchantWebService"/>

是否可以在插件配置中指定位置作为参数? locationUri不工作:(

添加

<locationUri>http://localhost:8080/AppRootContext/services/MerchantWebService</locationUri>
http://localhost:8080/AppRootContext/services/MerchantWebService
给你

<configuration>