From 9c402f9059713f5505a91d800cbf28337b6f8404 Mon Sep 17 00:00:00 2001 From: Iwein Fuld Date: Tue, 14 Oct 2008 19:55:48 +0000 Subject: [PATCH] added rmi.xml --- spring-integration-reference/src/file.xml | 41 +++++-------- spring-integration-reference/src/rmi.xml | 60 +++++++++++++++++++ .../src/spring-integration-reference.xml | 1 + 3 files changed, 75 insertions(+), 27 deletions(-) create mode 100644 spring-integration-reference/src/rmi.xml diff --git a/spring-integration-reference/src/file.xml b/spring-integration-reference/src/file.xml index e94c4d95b0..d98f8c3269 100644 --- a/spring-integration-reference/src/file.xml +++ b/spring-integration-reference/src/file.xml @@ -13,33 +13,23 @@ There is a namespace that enables elements that define channel adapters dedicated to files and support for transformers that transform files into strings or byte arrays. - + - This section will explain the workings ofPollableFileSource, - FileWritingMessageConsumer and how to configure them as - beans. Also the support for dealing with files through file specific - implementations of Transformer will be discussed. Finally - the file specific namespace will be explained. + This section will explain the workings of PollableFileSource, FileWritingMessageConsumer and how to configure them as beans. Also the support for dealing with files through file specific implementations of Transformer will be discussed. Finally the file specific namespace will be explained.
Reading Files - A - PollableFileSource - can be used to consume files from the filesystem. This is an - implementation of - PollableSource - that creates messages from a file system directory. + A PollableFileSource can be used to consume files from the filesystem. This is an implementation of PollableSource that creates messages from a file system directory. ]]> To prevent creating messages for certain files, you may supply a {@link FileListFilter}. By default, an - AcceptOnceFileListFilter - + AcceptOnceFileListFilter is used. This filter ensures files are picked up only once from the directory. ]]> Within this namespace you can reduce the PollableFileSource and wrap it in a InboundChannelAdapter like this: - (1) - (2) - (3) - ]]> - + (1) + (2) + (3)]]> Where (1) is relying on the default filter that just prevents duplication, (2) is using a custom filter and (3) is using the filename-pattern @@ -133,8 +121,7 @@ To make things easier you can configure the FileWritingMessageConsumer as part of an outbound channel adapter using the namespace. - - ]]> + ]]> If you have more elaborate requirements to the payload to file @@ -177,7 +164,7 @@ To configure File specific transformers you can use the appropriate elements from the file namespace. - ]]> + ]]> The delete-files option signals the transformer to delete the File after the diff --git a/spring-integration-reference/src/rmi.xml b/spring-integration-reference/src/rmi.xml new file mode 100644 index 0000000000..3143d9b59f --- /dev/null +++ b/spring-integration-reference/src/rmi.xml @@ -0,0 +1,60 @@ + + + + RMI + +
+ Introduction + + This Chapter explains how to use RMI specific channel adapters to distribute a system over multiple jvm's. The first section will deal with sending messages over RMI. The second section shows how to receive messages over RMI. The last section shows how to define rmi channel adapters through the namespace support + +
+ +
+ Outbound RMI + + To send messages from a channel over RMI, simply define an RmiOutboundGateway. This gateway will use Spring's RmiProxyFactoryBean internally to create a proxy for a remote gateway. Note that to invoke a remote interface that doesn't use Spring Integration you should use a service activator in combination with Spring's RmiProxyFactoryBean. + + + To configure the outbound gateway write a bean definition like this: + + + + ]]> + + +
+ +
+ Inbound RMI + + To receive messages over RMI you need to use a RmiInboundGateway. This gateway can be configured like this + + + ]]> + + +
+ +
+ RMI namespace support + + To configure the inbound gateway you can choose to use the namespace support for it. The following code snippet shows the different configuration options that are supported. + + + + + + + + + ]]> + + + To configure the outbound gateway you can use the namespace support as well. The following code snippet shows the different configuration for an outbound rmi gateway. + ]]> + +
+ +
\ No newline at end of file diff --git a/spring-integration-reference/src/spring-integration-reference.xml b/spring-integration-reference/src/spring-integration-reference.xml index 63db1f8465..bd48cb0654 100644 --- a/spring-integration-reference/src/spring-integration-reference.xml +++ b/spring-integration-reference/src/spring-integration-reference.xml @@ -36,6 +36,7 @@ +