Changes to make 'mvn clean test' succeed, add .springBean configuration where missing.
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
|
||||
package rg.springframework.integration.samples.ws;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.springframework.context.support.ClassPathXmlApplicationContext;
|
||||
import org.springframework.integration.Message;
|
||||
import org.springframework.integration.MessageChannel;
|
||||
@@ -31,12 +30,11 @@ import org.springframework.integration.support.channel.ChannelResolver;
|
||||
*
|
||||
* @author Marius Bogoevici
|
||||
*/
|
||||
public class WebServiceDemoTest {
|
||||
public class WebServiceDemoTestApp {
|
||||
|
||||
@Test
|
||||
public void testWsOutboundGateway() {
|
||||
public static void main(String[] args) {
|
||||
ClassPathXmlApplicationContext context =
|
||||
new ClassPathXmlApplicationContext("/META-INF/spring/integration/temperatureConversion.xml", WebServiceDemoTest.class);
|
||||
new ClassPathXmlApplicationContext("/META-INF/spring/integration/temperatureConversion.xml");
|
||||
ChannelResolver channelResolver = new BeanFactoryChannelResolver(context);
|
||||
|
||||
// Compose the XML message according to the server's schema
|
||||
@@ -52,4 +50,5 @@ public class WebServiceDemoTest {
|
||||
MessageChannel channel = channelResolver.resolveChannelName("fahrenheitChannel");
|
||||
channel.send(message);
|
||||
}
|
||||
|
||||
}
|
||||
36
basic/ws-outbound-gateway/src/main/resources/log4j.xml
Normal file
36
basic/ws-outbound-gateway/src/main/resources/log4j.xml
Normal file
@@ -0,0 +1,36 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
|
||||
<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
|
||||
|
||||
<!-- Appenders -->
|
||||
<appender name="console" class="org.apache.log4j.ConsoleAppender">
|
||||
<param name="Target" value="System.out" />
|
||||
<layout class="org.apache.log4j.PatternLayout">
|
||||
<param name="ConversionPattern" value="%-5p: %c - %m%n" />
|
||||
</layout>
|
||||
</appender>
|
||||
|
||||
<!-- Loggers -->
|
||||
<logger name="org.springframework">
|
||||
<level value="warn" />
|
||||
</logger>
|
||||
|
||||
<logger name="org.springframework.ws">
|
||||
<level value="warn" />
|
||||
</logger>
|
||||
|
||||
<logger name="org.springframework.integration">
|
||||
<level value="warn" />
|
||||
</logger>
|
||||
|
||||
<logger name="org.springframework.integration.ws">
|
||||
<level value="warn" />
|
||||
</logger>
|
||||
|
||||
<!-- Root Logger -->
|
||||
<root>
|
||||
<priority value="warn" />
|
||||
<appender-ref ref="console" />
|
||||
</root>
|
||||
|
||||
</log4j:configuration>
|
||||
Reference in New Issue
Block a user