Skip to content

Instantly share code, notes, and snippets.

@hkhamm
Last active December 14, 2018 09:47
Show Gist options
  • Save hkhamm/b700fe70f0025a519171 to your computer and use it in GitHub Desktop.
Save hkhamm/b700fe70f0025a519171 to your computer and use it in GitHub Desktop.
Install the Spark Cassandra Connector
#!/bin/bash
# Installs the spark-cassandra-connector and support libs
mkdir /opt/connector
cd /opt/connector
rm *.jar
curl -o ivy-2.3.0.jar \
'http://search.maven.org/remotecontent?filepath=org/apache/ivy/ivy/2.3.0/ivy-2.3.0.jar'
curl -o spark-cassandra-connector_2.10-1.0.0-rc2.jar \
'http://search.maven.org/remotecontent?filepath=com/datastax/spark/spark-cassandra-connector_2.10/1.0.0-rc2/spark-cassandra-connector_2.10-1.0.0-rc2.jar'
java -jar ivy-2.3.0.jar -dependency org.apache.cassandra cassandra-thrift 2.0.9 -retrieve "[artifact]-[revision](-[classifier]).[ext]"
java -jar ivy-2.3.0.jar -dependency com.datastax.cassandra cassandra-driver-core 2.0.3 -retrieve "[artifact]-[revision](-[classifier]).[ext]"
java -jar ivy-2.3.0.jar -dependency joda-time joda-time 2.3 -retrieve "[artifact]-[revision](-[classifier]).[ext]"
java -jar ivy-2.3.0.jar -dependency org.joda joda-convert 1.6 -retrieve "[artifact]-[revision](-[classifier]).[ext]"
rm -f *-{sources,javadoc}.jar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment