【问题标题】:how to put object to the aws s3 bucket using a spring boot-web application如何使用 Spring Boot-Web 应用程序将对象放入 aws s3 存储桶
【发布时间】:2020-06-30 12:26:39
【问题描述】:

如何在spring boot应用中读取请求体

aws --debug s3api --endpoint-url http://localhost:5555 put-object --bucket example_bucket --key test --body C:\Users\DELL\Desktop\test.txt

如何在我的 Spring Boot 应用程序中读取 --body 值,使其成为我的端点的请求正文

【问题讨论】:

标签: java spring amazon-web-services gradle amazon-s3


【解决方案1】:

https://cloud.spring.io/spring-cloud-aws/spring-cloud-aws.html#_resource_handling

您可以添加 spring-cloud-aws 或者通常您可以添加 spring cloud bom。 您也可以像上面的链接一样配置

【讨论】:

    【解决方案2】:

    您也可以使用minio-java。它是适用于 Amazon S3 兼容云存储的 SDK。

    【讨论】:

    • 我不想使用 aws sdk 我只想在 Spring Boot 应用程序中读取发布请求正文
    猜你喜欢
    • 1970-01-01
    • 2021-05-27
    • 1970-01-01
    • 2015-09-12
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-08-14
    • 1970-01-01
    相关资源
    最近更新 更多