Skip to content

Commit e5b681f

Browse files
GEOMESA-3484 Redis - Add cluster parameter to CLI tools (#3351)
1 parent 085c7eb commit e5b681f

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

docs/user/redis/commandline.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,4 @@ General Arguments
2121
-----------------
2222

2323
Most commands require that you specify the Redis URL, using ``--url`` or ``-u``.
24+
Additionally, if using a redis cluster, most commands require the cluster flag ``--cluster`` or ``-l``.

geomesa-redis/geomesa-redis-tools/src/main/scala/org/locationtech/geomesa/redis/tools/RedisDataStoreCommand.scala

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ trait RedisDataStoreCommand extends DataStoreCommand[RedisDataStore] {
2626
override def connection: Map[String, String] = {
2727
Map(
2828
RedisDataStoreParams.RedisUrlParam.key -> params.url,
29-
RedisDataStoreParams.RedisCatalogParam.key -> params.catalog
29+
RedisDataStoreParams.RedisCatalogParam.key -> params.catalog,
30+
RedisDataStoreParams.RedisClusterBoolParam.key -> params.cluster.toString
3031
)
3132
}
3233
}
@@ -47,5 +48,8 @@ object RedisDataStoreCommand {
4748
trait RedisDataStoreParams extends CatalogParam {
4849
@Parameter(names = Array("--url", "-u"), description = "Redis connection URL", required = true)
4950
var url: String = _
51+
52+
@Parameter(names = Array("--cluster", "-l"), description = "Redis cluster enabled?", required = false)
53+
var cluster: Boolean = false
5054
}
5155
}

0 commit comments

Comments
 (0)