Tutorial: https://blog.csdn.net/zhangxin09/article/details/137671230.
Java Documents: https://dev.ajaxjs.com/docs/javadoc/aj-s3client/.
Support these S3 Storages directly:
- Cloudflare R2
- Scaleway
- Backblaze
- Aliyun OSS
- Netease OSS
<dependency>
<groupId>com.ajaxjs</groupId>
<artifactId>aj-s3client</artifactId>
<version>1.1</version>
</dependency>
单元测试的配置文件application.yml
没有随着 VCS 提交,其内容如下:
S3Storage:
Nso:
accessKey: xx
accessSecret: xx
api: nos-eastchina1.126.net
bucket: xx
Oss:
accessKeyId: xx
secretAccessKey: xx
endpoint: oss-cn-beijing.aliyuncs.com
bucket: xx
LocalStorage: # 本地保存
absoluteSavePath: c:\temp\ # 若有此值,保存这个绝对路径上