INT-842 moved gateway support base classes to core gateway package
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2008 the original author or authors.
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -22,9 +22,9 @@ import javax.servlet.ServletException;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import org.springframework.integration.adapter.RemoteMessageHandler;
|
||||
import org.springframework.integration.adapter.RemotingInboundGatewaySupport;
|
||||
import org.springframework.integration.core.MessagingException;
|
||||
import org.springframework.integration.gateway.RemotingInboundGatewaySupport;
|
||||
import org.springframework.integration.gateway.RequestReplyExchanger;
|
||||
import org.springframework.remoting.httpinvoker.HttpInvokerServiceExporter;
|
||||
import org.springframework.web.HttpRequestHandler;
|
||||
|
||||
@@ -74,7 +74,7 @@ public class HttpInvokerInboundGateway extends RemotingInboundGatewaySupport imp
|
||||
if (this.exporter == null) {
|
||||
HttpInvokerServiceExporter exporter = new HttpInvokerServiceExporter();
|
||||
exporter.setService(this);
|
||||
exporter.setServiceInterface(RemoteMessageHandler.class);
|
||||
exporter.setServiceInterface(RequestReplyExchanger.class);
|
||||
exporter.afterPropertiesSet();
|
||||
this.exporter = exporter;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2008 the original author or authors.
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
package org.springframework.integration.httpinvoker;
|
||||
|
||||
import org.springframework.integration.adapter.AbstractRemotingOutboundGateway;
|
||||
import org.springframework.integration.adapter.RemoteMessageHandler;
|
||||
import org.springframework.integration.gateway.AbstractRemotingOutboundGateway;
|
||||
import org.springframework.integration.gateway.RequestReplyExchanger;
|
||||
import org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean;
|
||||
|
||||
/**
|
||||
@@ -36,12 +36,12 @@ public class HttpInvokerOutboundGateway extends AbstractRemotingOutboundGateway
|
||||
|
||||
|
||||
@Override
|
||||
protected RemoteMessageHandler createHandlerProxy(String url) {
|
||||
protected RequestReplyExchanger createProxy(String url) {
|
||||
HttpInvokerProxyFactoryBean proxyFactory = new HttpInvokerProxyFactoryBean();
|
||||
proxyFactory.setServiceInterface(RemoteMessageHandler.class);
|
||||
proxyFactory.setServiceInterface(RequestReplyExchanger.class);
|
||||
proxyFactory.setServiceUrl(url);
|
||||
proxyFactory.afterPropertiesSet();
|
||||
return (RemoteMessageHandler) proxyFactory.getObject();
|
||||
return (RequestReplyExchanger) proxyFactory.getObject();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2008 the original author or authors.
|
||||
* Copyright 2002-2010 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -85,7 +85,7 @@ public class HttpInvokerInboundGatewayTests {
|
||||
|
||||
private static byte[] createRequestContent(Message<?> message) throws IOException {
|
||||
RemoteInvocation invocation = new RemoteInvocation(
|
||||
"handle", new Class[] { Message.class }, new Object[] { message });
|
||||
"exchange", new Class[] { Message.class }, new Object[] { message });
|
||||
ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
|
||||
ObjectOutputStream oos = new ObjectOutputStream(baos);
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user