mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-20 06:08:03 +01:00
Move to a synchronous, pooled connection model for Redis clusters.
This commit is contained in:
committed by
Jon Chambers
parent
27f721a1f5
commit
6fb9038af1
@@ -14,10 +14,8 @@ public class RedisClusterHealthCheck extends HealthCheck {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Result check() throws Exception {
|
||||
return CompletableFuture.allOf(redisCluster.withCluster(connection -> connection.async().masters().commands().ping()).futures())
|
||||
.thenApply(v -> Result.healthy())
|
||||
.exceptionally(Result::unhealthy)
|
||||
.get();
|
||||
protected Result check() {
|
||||
redisCluster.withCluster(connection -> connection.sync().masters().commands().ping());
|
||||
return Result.healthy();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user