INT-3960: File Outbound - Preserve Timestamp
JIRA: https://jira.spring.io/browse/INT-3960 Polishing - PR Comments Fix errors according Checkstyle report. Wrap `warn()` to `isWarnEnable()`. Polishing for `setPreserveTimestamp()` JavaDocs.
This commit is contained in:
committed by
Artem Bilan
parent
ad0839da8b
commit
516846b750
@@ -105,7 +105,7 @@ to, say, network glitches.
|
||||
</bean>
|
||||
----
|
||||
|
||||
*The directory scanning and polling*
|
||||
*Directory scanning and polling*
|
||||
|
||||
The `FileReadingMessageSource` doesn't produce messages for files from the directory immediately.
|
||||
It uses an internal queue for 'eligible files' returned by the `scanner`.
|
||||
@@ -584,6 +584,18 @@ or `FileWritingMessageHandler.MessageFlushPredicate` implementation.
|
||||
The predicates are called for each open file.
|
||||
See the java docs for these interfaces for more information.
|
||||
|
||||
[[file-timestamps]]
|
||||
==== File Timestamps
|
||||
|
||||
By default, the destination file `lastModified` timestamp will be the time the file was created (except a rename
|
||||
in-place will retain the current timestamp).
|
||||
Starting with _version 4.3_, you can now configure `preserve-timestamp` (or `setPreserveTimestamp(true)` when using
|
||||
Java configuration).
|
||||
For `File` payloads, this will transfer the timestamp from the inbound file to the outbound (regardless of whether a
|
||||
copy was required).
|
||||
For other payloads, if the `FileHeaders.SET_MODIFIED` header (`file_setModified`) is present, it will be used to set
|
||||
the destination file's `lastModified` timestamp, as long as the header is a `Number`.
|
||||
|
||||
[[file-outbound-channel-adapter]]
|
||||
==== File Outbound Channel Adapter
|
||||
|
||||
|
||||
@@ -76,6 +76,11 @@ When writing files, you can now specify the buffer size to use.
|
||||
You can now avoid flushing files when appending and use a number of strategies to flush the data during idle periods.
|
||||
See <<file-flushing>> for more information.
|
||||
|
||||
===== Preserving Timestamps
|
||||
|
||||
The outbound channel adapter can now be configured to set the destination file's lastmodified timestamp.
|
||||
See <<file-timestamps>> for more information.
|
||||
|
||||
==== AMQP Changes
|
||||
|
||||
===== Content Type Message Converter
|
||||
|
||||
Reference in New Issue
Block a user