This commit is contained in:
Arjen Poutsma
2008-06-30 11:55:43 +00:00
parent c39df00abd
commit d5c097314a
4 changed files with 12 additions and 8 deletions

View File

@@ -38,7 +38,8 @@
<bean id="holiday" class="org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition">
<property name="schema" ref="schema"/>
<property name="portTypeName" value="HumanResource"/>
<property name="locationUri" value="http://localhost:8080/holidayService/"/>
<!-- we use a relative uri that will be transformed by spring-ws dep-->
<property name="locationUri" value="/holidayService/"/>
<property name="targetNamespace" value="http://mycompany.com/hr/definitions"/>
</bean>
@@ -46,4 +47,4 @@
<property name="xsd" value="/WEB-INF/hr.xsd"/>
</bean>
</beans>
</beans>

View File

@@ -24,6 +24,10 @@
<servlet>
<servlet-name>spring-ws</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>
</servlet>
<servlet-mapping>

View File

@@ -151,7 +151,7 @@
that means that it looks for '<filename>/WEB-INF/spring-ws-servlet.xml</filename>'. This file will
contain all of the SWS-specific beans such as endpoints, marshallers and suchlike.
</para>
<section>
<section id="server-automatic-wsdl-exposure">
<title>Automatic WSDL exposure</title>
<para>
The <classname>MessageDispatcherServlet</classname> will automatically detect any

View File

@@ -725,7 +725,7 @@ public class HolidayEndpoint extends AbstractJDomPayloadEndpoint {
<programlisting><![CDATA[<bean id="holiday" class="org.springframework.ws.wsdl.wsdl11.DefaultWsdl11Definition">
<property name="schema" ref="schema"/>
<property name="portTypeName" value="HumanResource"/>
<property name="locationUri" value="http://localhost:8080/holidayService/"/>
<property name="locationUri" value="/holidayService/"/>
<property name="targetNamespace" value="http://mycompany.com/hr/definitions"/>
</bean>
@@ -756,10 +756,9 @@ public class HolidayEndpoint extends AbstractJDomPayloadEndpoint {
<callout arearefs="tutorial.wsdl.gen.locationUri">
<para>
We set the location where the service can be reached:
<uri>http://localhost:8080/holidayService</uri>. For development, this will suffice, but
obviously we need to change this to <uri>http://mycompany.com/humanresources</uri> when going
live. A common way to to accomplish this is to use a Spring
<classname>PropertyPlaceholderConfigurer</classname>.
<uri>/holidayService/</uri>. We use a a relative URI and we instruct the framework to transform it
dynamically to an absolute URI. Hence, if the service is deployed to different contexts we don't have
to change the URI manually. For more information, please refer to <xref linkend="server-automatic-wsdl-exposure"/>
</para>
</callout>
<callout arearefs="tutorial.wsdl.gen.tns">