I referred to this https://github.com/awsdocs/amazon-s3-developer-guide/blob/master/doc_source/AuthUsingTempFederationTokenJava.md link but it shows a profile error that the profile file should not be null. another I referred this https://docs.aws.amazon.com/AmazonS3/latest/userguide/AuthUsingTempSessionToken.html even this doesn't work for me. any suggestion?
For both links you need to follow the instructions and not just copy/paste the code. The profile is null, because you most probably haven't created a ~/.aws/credentials file.
The process to test the code should be:
new ProfileCredentialsProvider("app-1-development")
in your code.Please also refer here
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.