Skip to content

Conversation

liujiang157
Copy link

切换本地和oss通过环境变了file.storage=local/s3控制
s3协议的相关配置均在S3StorageProperties类中

@CLAassistant
Copy link

CLAassistant commented Jun 16, 2025

CLA assistant check
All committers have signed the CLA.

@liujiang157
Copy link
Author

重新调整了代码,走本地还是 S3 通过 "hsweb.file.storage"来控制,S3相关配置也遵循之前配置属性的命名基础上添加。控制
如果是S3则:
System.setProperty("hsweb.file.storage", "s3");
如果本地则设置如下或者不设置:
System.setProperty("hsweb.file.storage", "local");

S3的相关配置:
hsweb.file.upload.s3.endpoint
hsweb.file.upload.s3.region
hsweb.file.upload.s3.accessKey
hsweb.file.upload.s3.secretKey
hsweb.file.upload.s3.bucket

单元测试成功之后我删除了accessKey和secretKey,其余问题也改掉了

修改error应当由Mono传递,而不是抛出异常
移除非必要Condition条件
采用buffer.asInputStream访问文件
移除冗余代码
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants