Get URL(link) of a public S3 object programmatically

后端 未结 7 706
心在旅途
心在旅途 2021-01-01 14:06

I am storing one public object in AWS S3 bucket using given java API in my server Now i need to return back the public URL of the S3 object to my client

Till now i h

7条回答
  •  情话喂你
    2021-01-01 14:55

    i am using aws-java-sdk-s3 1.11.58

    accepted answer not working on this version.

    below line works for this version

    s3Client.getUrl(AWS_BUCKET, s3RelativeFilePath).toExternalForm();
    

提交回复
热议问题