-
Notifications
You must be signed in to change notification settings - Fork 205
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to load credentials #227
Comments
Hi, Starting MultiLangDaemon ... For more information, visit: https://github.com/awslabs/amazon-kinesis-client |
From what I can tell, the java side of the kcl uses reflection to find and load resources from your .properties file. This config: AWSCredentialsProvider = STSAssumeRoleSessionCredentialsProvider|arn:aws:iam::955*********:role/FakeRoleForGithub**********|session2 lets the process know that it should find a class with the name I assume that the process can't locate a class called STSAssumeRoleSessionCredentialsProvider and fails to load any credentials and then throws the Here's what I did, but please make sure you don't just use this blindly: 1 - I downloaded the java aws-sdk .jar file and stored it locally. COPY ./docker/aws-java-sdk-1.12.496.jar ./java/aws-java-sdk-1.12.496.jar 3 - I then edited my npm script to tell it where my java files are:
4 - I modified my
So in your case it would be:
I'm not a java guru and it took me loads of reading up to get to this solution, so if i've done anything wrong, please let me know. Hope this helps you |
But even if you use default one from example: |
Hello,
I'm using aws-kcl v2.2.2 with node js v19.6.0
When i run the node_modules/aws-kcl/bin/kcl-boostrap file i have this issue :
Starting MultiLangDaemon ... java.lang.RuntimeException: java.lang.reflect.InvocationTargetException at software.amazon.kinesis.multilang.config.KinesisClientLibConfigurator.lambda$getConfiguration$0(KinesisClientLibConfigurator.java:67) at java.base/java.lang.Iterable.forEach(Iterable.java:75) at java.base/java.util.Collections$SynchronizedCollection.forEach(Collections.java:2067) at software.amazon.kinesis.multilang.config.KinesisClientLibConfigurator.getConfiguration(KinesisClientLibConfigurator.java:63) at software.amazon.kinesis.multilang.MultiLangDaemonConfig.<init>(MultiLangDaemonConfig.java:108) at software.amazon.kinesis.multilang.MultiLangDaemonConfig.<init>(MultiLangDaemonConfig.java:81) at software.amazon.kinesis.multilang.MultiLangDaemonConfig.<init>(MultiLangDaemonConfig.java:65) at software.amazon.kinesis.multilang.MultiLangDaemon.buildMultiLangDaemonConfig(MultiLangDaemon.java:171) at software.amazon.kinesis.multilang.MultiLangDaemon.main(MultiLangDaemon.java:220) Caused by: java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at org.apache.commons.beanutils.PropertyUtilsBean.invokeMethod(PropertyUtilsBean.java:2128) at org.apache.commons.beanutils.PropertyUtilsBean.setSimpleProperty(PropertyUtilsBean.java:2109) at org.apache.commons.beanutils.PropertyUtilsBean.setNestedProperty(PropertyUtilsBean.java:1915) at org.apache.commons.beanutils.PropertyUtilsBean.setProperty(PropertyUtilsBean.java:2022) at org.apache.commons.beanutils.BeanUtilsBean.setProperty(BeanUtilsBean.java:1018) at software.amazon.kinesis.multilang.config.KinesisClientLibConfigurator.lambda$getConfiguration$0(KinesisClientLibConfigurator.java:65) ... 8 more Caused by: java.lang.IllegalArgumentException: No credential providers specified at com.amazonaws.auth.AWSCredentialsProviderChain.<init>(AWSCredentialsProviderChain.java:59) at software.amazon.kinesis.multilang.config.AWSCredentialsProviderPropertyValueDecoder.decodeValue(AWSCredentialsProviderPropertyValueDecoder.java:57) at software.amazon.kinesis.multilang.config.MultiLangDaemonConfiguration.lambda$new$0(MultiLangDaemonConfiguration.java:249) at software.amazon.kinesis.multilang.config.BuilderDynaBean.set(BuilderDynaBean.java:258) at software.amazon.kinesis.multilang.config.MultiLangDaemonConfiguration.setAWSCredentialsProvider(MultiLangDaemonConfiguration.java:176) ... 18 more java.lang.reflect.InvocationTargetException
And the AWSCredentialsProvider value in my properties file is like this :
AWSCredentialsProvider = STSAssumeRoleSessionCredentialsProvider|arn:aws:iam::955*********:role/FakeRoleForGithub**********|session2
Do someone have the same problem ?
Please let me know 👍
The text was updated successfully, but these errors were encountered: