com.amazonaws.AmazonClientException:无法从任何提供程序加载AWS凭据

时间:2018-01-16 10:30:05

标签: java eclipse amazon-web-services amazon-s3 amazon-kinesis

我正在使用this kinesis到S3连接器。在运行S3Executor.java时,我遇到了异常。

Exception in thread "main" com.amazonaws.AmazonClientException: Unable to load AWS credentials from any provider in the chain
at com.amazonaws.auth.AWSCredentialsProviderChain.getCredentials(AWSCredentialsProviderChain.java:131)
at com.amazonaws.http.AmazonHttpClient.getCredentialsFromContext(AmazonHttpClient.java:780)
at com.amazonaws.http.AmazonHttpClient.executeOneRequest(AmazonHttpClient.java:806)
at com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:701)
at com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:453)
at com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:415)
at com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:364)
at com.amazonaws.services.kinesis.AmazonKinesisClient.doInvoke(AmazonKinesisClient.java:1998)
at com.amazonaws.services.kinesis.AmazonKinesisClient.invoke(AmazonKinesisClient.java:1968)
at com.amazonaws.services.kinesis.AmazonKinesisClient.describeStream(AmazonKinesisClient.java:686)
at com.connectors.util.KinesisUtils.streamExists(KinesisUtils.java:150)
at com.connectors.util.KinesisUtils.createAndWaitForStreamToBecomeAvailable(KinesisUtils.java:82)
at com.connectors.util.KinesisUtils.createInputStream(KinesisUtils.java:41)
at com.connectors.util.StreamSource.<init>(StreamSource.java:66)
at com.connectors.util.KinesisConnectorExecutor.setupInputStream(KinesisConnectorExecutor.java:181)
at com.connectors.util.KinesisConnectorExecutor.<init>(KinesisConnectorExecutor.java:100)
at com.connectors.util.S3Executor.<init>(S3Executor.java:22)
at com.connectors.util.S3Executor.main(S3Executor.java:37)

我在Eclipse中设置了Access Id和Secret Key。它适用于另一个S3示例项目。但在这个连接器中,我遇到了这个问题。

感谢任何帮助

0 个答案:

没有答案