Current latest version - 0.1.11
To use this jar -
- Add the dependency in pom.xml io.github.dinakaranram9 aws-s3-wrapper 0.1.11
- Add @EnableS3Bucket in main class that enables the application to create beans defined inside the jar.
- Autowire S3Client from package com.dinakaran.awss3wrapper.upload
- Function upload accepts Multipart file as parameter and returns the path in s3 bucket.
- Function downlaod accepts the path of the file as parameter and returns the file from s3 bucket.
- Add the following properties in application.properties file that enables to connect to s3 bucket. spring.s3.accessKey=XXX spring.s3.secret=XXX spring.s3.endpointUrl=XXX spring.s3.bucketName=XXX spring.s3.applicationPath=default/ spring.s3.env=local/
Fore demo please follow the following github link : https://github.com/dinakaranram9/aws-s3-wrapper-jar-demo.git
The jar aws-s3-wrapper is under MIT license. Please feel free to contribute towards it if you like it or request for new features. I will try to implement new features in upcoming releases.