gpt4 book ai didi

java - 获取不存在的对象时状态代码 : 403,

转载 作者:塔克拉玛干 更新时间:2023-11-02 19:32:18 25 4
gpt4 key购买 nike

我有一个用户 - 管理器,分配了 S3Actions.GetObject、S3Actions.PutObject

  • 当我放入对象并得到它时,一切都很好
  • 当我得到一个不存在的对象时,它抛出

Status Code: 403, AWS Service: Amazon S3, AWS Request ID: 2A23D3118F9FFB08, AWS Error Code: AccessDenied, AWS Error Message: Access Denied, S3 Extended Request ID: 3h4D2Ks9skcSab3zkV/nedmm9b8WLL+92DESbOx9xGipkH7P69QQiJLVWyDowASi
at com.amazonaws.http.AmazonHttpClient.handleErrorResponse(AmazonHttpClient.java:556)
at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:289)
at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:170)
at com.amazonaws.services.s3.AmazonS3Client.invoke(AmazonS3Client.java:2724)
at com.amazonaws.services.s3.AmazonS3Client.getObject(AmazonS3Client.java:866)
at com.sr.sparrow.business.xml.persist.S3Service.getInputStream(S3Service.java:58)

为什么它不抛出 404/NoSuchKey

最佳答案

正如user1585811指出的,这是最好的解释

https://forums.aws.amazon.com/thread.jspa?messageID=210268

关于java - 获取不存在的对象时状态代码 : 403,,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12376344/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com