Connecting to Athena using JDBC driver from a Spring Java application

0

Hello,

I am trying to connect to Athena via latest (2.16) JDBC driver jar from a Java Spring web application. The application also connects to S3 to upload files there. I am seeing this exception when bean for s3 client is being instantiated on addition of the Athena JDBC jar.

I tried upgrading aws-java-sdk-core to 1.11.793 and also latest 1.11.998 as suggested in this post, but it is not helping
https://stackoverflow.com/questions/57260883/java-lang-securityexception-awscredentialsprovider-signer-information-does-not-m

Caused by: com.simba.athena.support.exceptions.GeneralException: [Simba][AthenaJDBC](100191) Failed to create AWS Credentials Provider class: com.amazonaws.auth.DefaultAWSCredentialsProviderChain.
_ ... 61 more_
Caused by: java.lang.ClassNotFoundException: com.amazonaws.auth.DefaultAWSCredentialsProviderChain
_ at java.net.URLClassLoader.findClass(URLClassLoader.java:382) ~[?:1.8.0_221]_
_ at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_221]_
_ at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_221]_
_ at java.lang.Class.forName0(Native Method) ~[?:1.8.0_221]_
_ at java.lang.Class.forName(Class.java:264) ~[?:1.8.0_221]_
_ at com.simba.athena.athena.utilities.AJUtilities.createAwsCredentialsProvider(Unknown Source) ~[AthenaJDBC42.jar:?]_

asked 3 years ago1417 views
1 Answer
0

Hi info2anu,

Based on the error it looks like you are missing a class your code depends on. I'd review the API and class doc carefully for build time requirements.

Regards,
-Kurt

klarson
answered 3 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions