The source and target adapters for HttpInvoker are very similar to the RMI adapters. For a source, only the
channel needs to be provided, and for a target, only the URL. If running in a Spring MVC environment, then
the HttpInvokerSourceAdapter simply needs to be defined and provided in a
HandlerMapping. For example, the following would be exposed at the path
"http://somehost/path-mapped-to-dispatcher-servlet/httpInvokerAdapter" when a simple
BeanNameUrlHandlerMapping strategy is enabled:
<bean name="/httpInvokerAdapter"
class="org.springframework.integration.adapter.httpinvoker.HttpInvokerSourceAdapter">
<constructor-arg ref="someChannel"/>
</bean>
When not running in a Spring MVC application, simply define a servlet in 'web.xml' whose type is
HttpRequestHandlerServlet and whose name matches the bean name of the source
adapter. As with the RmiTargetAdapter, the
HttpInvokerTargetAdapter only requires the URL that matches an instance of
HttpInvokerSourceAdapter running in a web application.