From 25c421e82c63b4af1c3a5b0fcd5ff3e692876801 Mon Sep 17 00:00:00 2001 From: Gunnar Hillert Date: Fri, 29 Jul 2011 16:52:53 -0400 Subject: [PATCH] Fixed #INT-2021 Clean up formatting issues in chapter 11 (File Support) of the reference documentation; #INT-1967 Standardize namespace pre-fixes in documentation --- docs/src/reference/docbook/file.xml | 58 ++++++++++++++--------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/docs/src/reference/docbook/file.xml b/docs/src/reference/docbook/file.xml index 0c02365238..3ab3d97883 100644 --- a/docs/src/reference/docbook/file.xml +++ b/docs/src/reference/docbook/file.xml @@ -71,8 +71,8 @@ + - + - + - ]]> + ]]> The first channel adapter is relying on the default filter that just prevents duplication, the second is using a custom filter, the third is using the filename-pattern attribute to add an AntPathMatcher @@ -112,23 +112,23 @@ them from being picked up concurrently. To do this you can use a FileLocker. There is a java.nio based implementation available out of the box, but it is also possible to implement your own locking scheme. The nio locker can be injected as follows - - - ]]> + + + ]]> A custom locker you can configure like this: - - - ]]> + + + ]]> When a file inbound adapter is configured with a locker, it will take the responsibility to acquire a lock before the file is allowed to be received. - It will not assume the responsibility to unlock the file. + It will not assume the responsibility to unlock the file. If you have processed the file and keeping the locks hanging around you have a memory leak. If this is a problem in your case you should call FileLocker.unlock(File file) yourself at the appropriate time. @@ -140,7 +140,7 @@ that Spring Integration uses internally to wire FileListFilters FileLocker to the FileReadingMessageSource. A custom DirectoryScanner can be injected into the <file:inbound-channel-adapter/> on the scanner attribute. - ]]> This gives you full freedom to choose the ordering, listing and locking strategies. @@ -166,13 +166,13 @@ To make things easier you can configure the FileWritingMessageHandler as part of an outbound channel adapter using the namespace. - ]]> + ]]> The namespace based configuration also supports a delete-source-files attribute. If set to true, it will trigger deletion of the original source files after writing to a destination. The default value for that flag is false. - ]]> @@ -188,13 +188,13 @@ the outbound-gateway instead. It plays a very similar role as the outbound-channel-adapter. However after writing the File, it will also send it to the reply channel as the payload of a Message. - ]]> - The 'outbound-gateway' works well in cases where you want to first move a File and then send it + The 'outbound-gateway' works well in cases where you want to first move a file and then send it through a processing pipeline. In such cases, you may connect the file namespace's 'inbound-channel-adapter' element to the 'outbound-gateway' and then connect that gateway's reply-channel to the beginning of the pipeline. @@ -229,10 +229,10 @@ To configure File specific transformers you can use the appropriate elements from the file namespace. - - ]]> The delete-files option signals to the transformer that it should delete the inbound File after the transformation is complete. This is in no way a replacement for using the