First release of the iPython notebook spark-kernel with Cassandra support
slowenthal
released this
20 Aug 23:41
·
8 commits
to cassandra
since this release
First release of the iPython notebook spark-kernel with Cassandra support
To get ipython notebook
Obviously you need python. Install these python packages
pip install ipython
pip install notebook
To set it up:
unpack the zip file
create the directory
~/.ipython/kernels/spark
create the file
~/.ipython/kernels/spark/kernel.json
and paste in the following contents: Note you need to update a path to sparkkernel
{
"display_name": "Spark 1.2.1 (Scala 2.10.4)",
"language": "scala",
"argv": [
"/<path>/<to>/spark-kernel/bin/sparkkernel",
"--profile",
"{connection_file}",
],
"codemirror_mode": "scala"
}
If you nee to override the connection host, add these lines to the argv map above
"--spark-configuration",
"spark.cassandra.connection.host=127.0.0.1"
To run it
ipython notebook
In the browser - create a new spark notebook
... and spark away
If you don't get output, try adding a .toString on the end. There seems to be a bug rendering some types.