Class S3InboundFileSynchronizer
java.lang.Object
org.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
org.springframework.integration.aws.inbound.S3InboundFileSynchronizer
- All Implemented Interfaces:
Closeable,AutoCloseable,org.springframework.beans.factory.Aware,org.springframework.beans.factory.BeanFactoryAware,org.springframework.beans.factory.BeanNameAware,org.springframework.beans.factory.InitializingBean,org.springframework.integration.file.remote.synchronizer.InboundFileSynchronizer
public class S3InboundFileSynchronizer
extends org.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
An implementation of
AbstractInboundFileSynchronizer for Amazon S3.- Author:
- Artem Bilan
-
Field Summary
Fields inherited from class org.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer
EXPRESSION_PARSER, logger -
Constructor Summary
ConstructorsConstructorDescriptionS3InboundFileSynchronizer(org.springframework.integration.file.remote.session.SessionFactory<software.amazon.awssdk.services.s3.model.S3Object> sessionFactory) Create a synchronizer with theSessionFactoryused to acquireSessioninstances.S3InboundFileSynchronizer(software.amazon.awssdk.services.s3.S3Client amazonS3) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleancopyFileToLocalDirectory(String remoteDirectoryPath, org.springframework.expression.EvaluationContext localFileEvaluationContext, software.amazon.awssdk.services.s3.model.S3Object remoteFile, File localDirectory, org.springframework.integration.file.remote.session.Session<software.amazon.awssdk.services.s3.model.S3Object> session) protected StringgetFilename(software.amazon.awssdk.services.s3.model.S3Object file) protected longgetModified(software.amazon.awssdk.services.s3.model.S3Object file) protected booleanisFile(software.amazon.awssdk.services.s3.model.S3Object file) protected Stringprotocol()Methods inherited from class org.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer
afterPropertiesSet, close, doInit, doSetFilter, doSetRemoteDirectoryExpression, filterFiles, getComparator, getRemoteFileMetadata, getTemporaryFileSuffix, removeRemoteFileMetadata, rollbackFromFileToListEnd, setBeanFactory, setBeanName, setComparator, setDeleteRemoteFiles, setFilter, setLocalFilenameGeneratorExpression, setLocalFilenameGeneratorExpressionString, setMetadataStorePrefix, setPreserveTimestamp, setRemoteDirectory, setRemoteDirectoryExpression, setRemoteDirectoryExpressionString, setRemoteFileMetadataStore, setRemoteFileSeparator, setTemporaryFileSuffix, synchronizeToLocalDirectory, synchronizeToLocalDirectory
-
Constructor Details
-
S3InboundFileSynchronizer
public S3InboundFileSynchronizer() -
S3InboundFileSynchronizer
public S3InboundFileSynchronizer(software.amazon.awssdk.services.s3.S3Client amazonS3) -
S3InboundFileSynchronizer
public S3InboundFileSynchronizer(org.springframework.integration.file.remote.session.SessionFactory<software.amazon.awssdk.services.s3.model.S3Object> sessionFactory) Create a synchronizer with theSessionFactoryused to acquireSessioninstances.- Parameters:
sessionFactory- The session factory.
-
-
Method Details
-
isFile
protected boolean isFile(software.amazon.awssdk.services.s3.model.S3Object file) - Specified by:
isFilein classorg.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
-
getFilename
- Specified by:
getFilenamein classorg.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
-
getModified
protected long getModified(software.amazon.awssdk.services.s3.model.S3Object file) - Specified by:
getModifiedin classorg.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
-
copyFileToLocalDirectory
protected boolean copyFileToLocalDirectory(String remoteDirectoryPath, @Nullable org.springframework.expression.EvaluationContext localFileEvaluationContext, software.amazon.awssdk.services.s3.model.S3Object remoteFile, File localDirectory, org.springframework.integration.file.remote.session.Session<software.amazon.awssdk.services.s3.model.S3Object> session) throws IOException - Overrides:
copyFileToLocalDirectoryin classorg.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>- Throws:
IOException
-
protocol
- Specified by:
protocolin classorg.springframework.integration.file.remote.synchronizer.AbstractInboundFileSynchronizer<software.amazon.awssdk.services.s3.model.S3Object>
-