У меня есть проблема с автоматической генераторной с помощью WSDL DefaultWsdl11DefinitionАвто производящая с помощью WSDL DefaultWsdl11Definition
ContactServiceOperations.xsd
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://com/blog/samples/webservices/contactservice"
xmlns:Contact="http://webservices.samples.blog.com" targetNamespace="http://com/blog/samples/webservices/Contact"
elementFormDefault="qualified">
<xsd:import namespace="http://webservices.samples.blog.com"
schemaLocation="Contact.xsd" />
<xsd:element name="ContactRequest">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Id" type="xsd:integer" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="ContactResponse">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="Contact" type="Contact:Contact" />
</xsd:sequence>
</xsd:complexType>
</xsd:element>
springapp-servlet.xml
<mvc:annotation-driven />
<sws:annotation-driven />
<context:component-scan base-package="*" />
<bean id="ContactService"
class="org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition">
<property name="schemaCollection">
<bean
class="org.springframework.xml.xsd.commons.CommonsXsdSchemaCollection">
<property name="inline" value="true" />
<property name="xsds">
<list>
<value>/xsd/ContactServiceOperations.xsd</value>
</list>
</property>
</bean>
</property>
<property name="portTypeName" value="ContactService" />
<property name="locationUri" value="http://localhost:8080/SpringWS/ContactService/" />
</bean>
веб .xml
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
</welcome-file-list>
<servlet>
<servlet-name>springapp</servlet-name>
<servlet-class>
org.springframework.web.servlet.DispatcherServlet
</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>springapp</servlet-name>
<url-pattern>/jsp/*</url-pattern>
</servlet-mapping>
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>classpath*:*.xml</param-value>
</context-param>
<listener>
<listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
<servlet>
<servlet-name>webservices</servlet-name>
<servlet-class>org.springframework.ws.transport.http.MessageDispatcherServlet</servlet-class>
<init-param>
<param-name>transformWsdlLocations</param-name>
<param-value>true</param-value>
</init-param>
<init-param>
<param-name>contextConfigLocation</param-name>
<param-value></param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>webservices</servlet-name>
<url-pattern>*.wsdl</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>webservices</servlet-name>
<url-pattern>/ContactService/*</url-pattern>
</servlet-mapping>
Я могу запустить Tomcat без ошибок. Затем я получаю доступ к этому URL-адресу: http://localhost:8080/SpringWS/ContactService/contactService.wsdl
И браузер показывает пустую страницу вместо сгенерированного wsdl.
Возможно, у меня что-то не так в конфигурации. Любая идея помочь мне?
Благодаря
Я попробовал, и я получил пустую страницу (ничего не появилось в моем браузере). Любое решение? –