Files
spring-integration-samples/basic/ws-inbound-gateway
Gunnar Hillert 9effe2f9bc INTSAMPLES-33 Update to SI RC1 and Spring 3.1
1. Cleanup of pom.xml files
2. Standardizing version numbers
3. Updating dependency versions
4. Cleaning/Standardizing project names
5. Removing Schema versions in XML context files
2011-12-18 00:32:34 -05:00
..

This sample demonstrates a barebones inbound Web Service Gateway. Take a look at "web.xml" in the WEB-INF directory where the Spring Web Services Message-dispatching Servlet is defined. Then have a look at the "spring-ws-config.xml" file (also in the WEB-INF directory) where the Spring WS EndpointMapping is defined. Finally view the Spring Integration configuration in the "inbound-gateway-config.xml" file within the "org.springframework.integration.samples.ws" package where the actual gateway is defined along with a channel and service-activator.

To use the gateway, you can run the tests that are located within the "src/test/java" directory. One is for standalone testing of the gateway itself, while the other tests the gateway running on a web server. The latter uses Spring Web Services' client-side support. Alternatively, you can simply start the server, and then send invocations with any standalone HTTP client testing tool. The request format should be similar to the following and should be POSTed to the service URL (e.g. http://localhost:8080/ws-inbound-gateway/echoservice):

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
<echoRequest xmlns="http://www.springframework.org/spring-ws/samples/echo">hello</echoRequest>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>