Download Amazon Redshift Jdbc Driver

Active2 months ago

Amazon Redshift JDBC Driver 1.2.1 Release Notes. Known Issues. The following are known issues that you may encounter due to limitations in the data.

I've downloaded the RedshiftJDBC41-1.1.17.1007.jar to use the com.amazon.redshift.jdbc41.Driver for some Redshift POC work that I'm doing, and have been adding it manually to my classpath.

I'd like to now incorporate it into our build, but I can't seem to find an example of a dependency name for it to put in my build.gradle file or find it in a Maven repo. Any tips? (Note, I'm looking for redshift jdbc only, not the older postgres-redshift driver).

Tunaki

Aws Redshift Jdbc

97.1k24 gold badges224 silver badges306 bronze badges
elduffelduff
9132 gold badges10 silver badges21 bronze badges

7 Answers

Redshift JDBC drivers are now available on maven repo. Look at http://docs.aws.amazon.com/redshift/latest/mgmt/configure-jdbc-connection-with-maven.html

nicolanicola
6791 gold badge8 silver badges25 bronze badges

The first thing to realize is that amazon documentation tells you to load the v4 version of the driver JAR file. If you downloaded the driver you got a v4X version of the driver so your code should be:

NOT

Note the addition of the version number in the first example!

The driver jar is here:

http://docs.aws.amazon.com/redshift/latest/mgmt/configure-jdbc-connection.html

Amazon does not publish to Maven (Come on Amazon WTF?) so you have to import the jar you download. The Maven import command (for JDBC) looks like this:

mvn install:install-file -Dfile=./RedshiftJDBC41-1.1.10.1010.jar -DgroupId=com.amazon -DartifactId=redshift.jdbc41 -Dversion=1.1.10.1010 -Dpackaging=jar -DgeneratePom=true

The Maven dependency looks like this (Note that the artificatID and Version should be what you gave it in the mvn command above. If the driver has been updated, then the mvn command and the dependency fields have to change):

David UrryDavid Urry
6681 gold badge7 silver badges14 bronze badges

Simple reason why they don't upload to public repo: Licensing.

I wasted many hours because of it. An hour to figure out to find it in maven repo and finding the reason (reading about people comments etc). An hour to upload it to internal repository. Then figuring out how to use it with AWS Lambda.

Amazon doesn't publish RedShift JDBC driver to any public repository, due to some stupid licensing/legal issues. They use LOT of open source projects, but don't contribute anything back to community. Just this redshift driver is an example.

Its a customer centric company, but still there are some legal folks who don't do their work properly. Btw, I'm an ex-employee of amazon.

devsathish

Amazon S3

devsathish
1,4761 gold badge15 silver badges15 bronze badges

Amazon does not publish to Maven so you have to import the jar you download.

Gradle

  1. download driver2.create libs folder on the root directory of project

  2. add in the build.gradle

JAVA USAGE EXAMPLE

dnocodednocode
1,0831 gold badge13 silver badges19 bronze badges

It seems this artifact is not available in any Maven repo. I was able to find the redshift JDBC driver for version 1.1.2.0002 on this GitHub repo but this is not the version you are looking for.

Your best bet would be to manually add this dependency using:

TunakiTunaki
97.1k24 gold badges224 silver badges306 bronze badges

The easiest way is to add Amazon's Redshift repo to your gradle build file, and then include the dependency like this.

Download Com.amazon.redshift.jdbc4.driver

build.gradle:

Google Bigquery

Rori StumpfRori Stumpf

Download Amazon Redshift Jdbc Driver

Paul Roub

Download Amazon Redshift Jdbc Driver

Download amazon redshift jdbc driver
33.3k8 gold badges62 silver badges77 bronze badges
AlexAlex

Not the answer you're looking for? Browse other questions tagged mavengradleamazon-redshift or ask your own question.