Created
December 30, 2013 23:22
-
-
Save SingleShot/8189916 to your computer and use it in GitHub Desktop.
You can read the Spring Integration flow as follows:
1. Receive a java object from the RsmpMessageSender interface, placing it on the rsmpOutboundJava channel.
2. Transform it to a JSON String, placing the result on the rsmpOutboutJson channel.
3. Transform the JSON String to bytes.
4. Publish the bytes to a TCP connection (the RSMP server). Ite…
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<beans xmlns="http://www.springframework.org/schema/beans" | |
xmlns:int="http://www.springframework.org/schema/integration" | |
xmlns:int-ip="http://www.springframework.org/schema/integration/ip" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd | |
http://www.springframework.org/schema/integration http://www.springframework.org/schema/integration/spring-integration.xsd | |
http://www.springframework.org/schema/integration/ip http://www.springframework.org/schema/integration/ip/spring-integration-ip.xsd"> | |
<int:gateway id="rsmpOutboundGateway" | |
service-interface="se.capelon.protocolhandler.rsmp.client.RsmpMessageSender" | |
default-request-channel="rsmpOutboundJava"/> | |
<int:channel id="rsmpOutboundJava"/> | |
<int:object-to-json-transformer input-channel="rsmpOutboundJava" | |
object-mapper="rsmpJsonMapper" | |
output-channel="rsmpOutboundJson"/> | |
<int:publish-subscribe-channel id="rsmpOutboundJson"/> | |
<int:transformer input-channel="rsmpOutboundJson" | |
expression="payload.getBytes()" | |
output-channel="rsmpOutboundBytes"/> | |
<int:channel id="rsmpOutboundBytes"/> | |
<int-ip:tcp-outbound-channel-adapter id="rsmpOutboundClient" | |
channel="rsmpOutboundBytes" | |
connection-factory="rsmpConnectionFactory"/> | |
</beans> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment