Available on crate feature
s3 only.Expand description
§S3 Tasklet
This module provides tasklets for Amazon S3 file transfer operations (put and get). It is designed to be similar to Spring Batch’s S3 capabilities for batch file transfers.
§Features
- S3 PUT operations (upload local files to S3)
- S3 GET operations (download S3 objects to local files, streaming)
- S3 PUT FOLDER operations (upload entire local folder to an S3 prefix)
- S3 GET FOLDER operations (download all objects under an S3 prefix to a local folder)
- Explicit credential configuration (access key / secret key)
- AWS default credential chain (environment variables,
~/.aws/credentials, IAM role) - Custom endpoint URL for S3-compatible services (MinIO, LocalStack)
- Configurable multipart upload chunk size
§Examples
§S3 PUT Operation
use spring_batch_rs::tasklet::s3::put::S3PutTaskletBuilder;
let tasklet = S3PutTaskletBuilder::new()
.bucket("my-bucket")
.key("exports/file.csv")
.local_file("./output/file.csv")
.region("eu-west-1")
.build()?;§S3 GET Operation
use spring_batch_rs::tasklet::s3::get::S3GetTaskletBuilder;
let tasklet = S3GetTaskletBuilder::new()
.bucket("my-bucket")
.key("imports/file.csv")
.local_file("./input/file.csv")
.region("eu-west-1")
.build()?;§S3 with MinIO (custom endpoint)
use spring_batch_rs::tasklet::s3::put::S3PutTaskletBuilder;
let tasklet = S3PutTaskletBuilder::new()
.bucket("my-bucket")
.key("file.csv")
.local_file("./output/file.csv")
.endpoint_url("http://localhost:9000")
.access_key_id("minioadmin")
.secret_access_key("minioadmin")
.build()?;Modules§
- get
- S3 GET tasklets for downloading files and folders from Amazon S3.
- put
- S3 PUT tasklets for uploading files and folders to Amazon S3.
Structs§
- S3Client
Config - Configuration for connecting to an S3-compatible service.