我使用aws-java-sdk-bom来上传文件:

final PutObjectRequest putRequest = new PutObjectRequest(bucketName, blobKey.toString(), input, metadata);
putRequest.setCannedAcl(CannedAccessControlList.PublicRead);

final ProgressTracker progress = new ProgressTracker();
transferManager.upload(putRequest, new S3ProgressListenerChain(progress));


并且我注意到,有时候,如果我在请求成功完成后立即尝试访问URL(通常是针对大于20Mb的大文件),则会以403响应。一秒钟后-一切正常。有超时或什么吗?

最佳答案

您应该参考AWS S3常见问题解答,我相信它花费的时间很少...

http://docs.aws.amazon.com/AmazonS3/latest/dev/Introduction.html#ConsistencyModel

07-24 20:49