A connector for Spark that allows reading and writing to/from Redis cluster
@RedisLabs / (3)
A library for reading and writing data from and to Redis with Apache Spark, for Spark SQL and DataFrames.
Spark-Redis provides access to all of Redis' data structures - String, Hash, List, Set and Sorted Set - from Spark as RDDs. The library can be used both with Redis stand-alone as well as clustered databases. When used with Redis cluster, Spark-Redis is aware of its partitioning scheme and adjusts in response to resharding and node failure events.
Include this package in your Spark Applications using:
spark-shell, pyspark, or spark-submit
> $SPARK_HOME/bin/spark-shell --packages com.redislabs:spark-redis:2.3.0
In your sbt build file, add:
libraryDependencies += "com.redislabs" % "spark-redis" % "2.3.0"
MavenIn your pom.xml, add:
<dependencies> <!-- list of dependencies --> <dependency> <groupId>com.redislabs</groupId> <artifactId>spark-redis</artifactId> <version>2.3.0</version> </dependency> </dependencies>