访问我的网络服务时获取异常:
org.apache.ws.commons.schema.XmlSchemaException:无法找到 相对于'test.xsd'导入的文档 'JNDI:/本地主机/ PROJ / WEB-INF / WSDL / testwsdl#types1'
答案 0 :(得分:3)
我在战争中访问了webservice,忘了在WEB-INF下包含.xsd文件
<plugin>
<artifactId>maven-war-plugin</artifactId>
<version>2.3</version>
<configuration>
<webXml>src/main/webapp/WEB-INF/web.xml</webXml>
<webResources>
<resource>
<directory>../service/src/main/resources</directory>
<targetPath>WEB-INF/wsdl</targetPath>
<includes>
<include>*.wsdl</include>
<include>*.xsd</include>
</includes>
</resource>
</webResources>
</configuration>
</plugin>