Skip to content

Commit

Permalink
Merge pull request spring-projects#42 from ghillert/INTSAMPLES-56
Browse files Browse the repository at this point in the history
INTSAMPLES-56 Update README.md for ws-outbound-gateway sample
  • Loading branch information
garyrussell committed Feb 9, 2012
2 parents 97dae9e + cf68ac2 commit 4dc47bf
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 6 deletions.
5 changes: 4 additions & 1 deletion basic/ws-outbound-gateway/README.md
Expand Up @@ -14,4 +14,7 @@ A very simple example that show you how easy it is to invoke a SOAP based servic
* The *WS Outbound Gateway* converts the Message to a SOAP request and sends it to a remote service, which converts a temperature from * The *WS Outbound Gateway* converts the Message to a SOAP request and sends it to a remote service, which converts a temperature from
Fahrenheit to Celsius and the result is printed to the console. Fahrenheit to Celsius and the result is printed to the console.


To run sample simply execute **WebServicesDemoTest** To run the sample simply execute **WebServiceDemoTestApp** in package *org.springframework.integration.samples.ws*. You can also execute that class using the [Exec Maven Plugin](http://mojo.codehaus.org/exec-maven-plugin/):

$ mvn clean package exec:java

8 changes: 8 additions & 0 deletions basic/ws-outbound-gateway/pom.xml
Expand Up @@ -62,6 +62,14 @@
<showDeprecation>false</showDeprecation> <showDeprecation>false</showDeprecation>
</configuration> </configuration>
</plugin> </plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>1.2</version>
<configuration>
<mainClass>org.springframework.integration.samples.ws.WebServiceDemoTestApp</mainClass>
</configuration>
</plugin>
</plugins> </plugins>
</build> </build>
<repositories> <repositories>
Expand Down
@@ -1,5 +1,5 @@
/* /*
* Copyright 2002-2010 the original author or authors. * Copyright 2002-2012 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
Expand All @@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */


package rg.springframework.integration.samples.ws; package org.springframework.integration.samples.ws;


import org.springframework.context.support.ClassPathXmlApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.integration.Message; import org.springframework.integration.Message;
Expand All @@ -27,13 +27,13 @@
* Demonstrates a web service invocation through a Web Service outbound Gateway. * Demonstrates a web service invocation through a Web Service outbound Gateway.
* A header-enricher provides the Soap Action prior to invocation. See the * A header-enricher provides the Soap Action prior to invocation. See the
* 'temperatureConversion.xml' configuration file for more detail. * 'temperatureConversion.xml' configuration file for more detail.
* *
* @author Marius Bogoevici * @author Marius Bogoevici
*/ */
public class WebServiceDemoTestApp { public class WebServiceDemoTestApp {


public static void main(String[] args) { public static void main(String[] args) {
ClassPathXmlApplicationContext context = ClassPathXmlApplicationContext context =
new ClassPathXmlApplicationContext("/META-INF/spring/integration/temperatureConversion.xml"); new ClassPathXmlApplicationContext("/META-INF/spring/integration/temperatureConversion.xml");
ChannelResolver channelResolver = new BeanFactoryChannelResolver(context); ChannelResolver channelResolver = new BeanFactoryChannelResolver(context);


Expand All @@ -50,5 +50,5 @@ public static void main(String[] args) {
MessageChannel channel = channelResolver.resolveChannelName("fahrenheitChannel"); MessageChannel channel = channelResolver.resolveChannelName("fahrenheitChannel");
channel.send(message); channel.send(message);
} }

} }

0 comments on commit 4dc47bf

Please sign in to comment.