mirror of
https://github.com/signalapp/Signal-Server
synced 2026-04-20 11:08:05 +01:00
Remove unused classes and methods
This commit is contained in:
committed by
Jon Chambers
parent
7a5615182a
commit
fef37f739b
@@ -1,32 +0,0 @@
|
||||
/*
|
||||
* Copyright 2013-2020 Signal Messenger, LLC
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
package org.whispersystems.textsecuregcm.providers;
|
||||
|
||||
import com.codahale.metrics.health.HealthCheck;
|
||||
import org.whispersystems.textsecuregcm.redis.ReplicatedJedisPool;
|
||||
|
||||
import redis.clients.jedis.Jedis;
|
||||
|
||||
public class RedisHealthCheck extends HealthCheck {
|
||||
|
||||
private final ReplicatedJedisPool clientPool;
|
||||
|
||||
public RedisHealthCheck(ReplicatedJedisPool clientPool) {
|
||||
this.clientPool = clientPool;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Result check() throws Exception {
|
||||
try (Jedis client = clientPool.getWriteResource()) {
|
||||
client.set("HEALTH", "test");
|
||||
|
||||
if (!"test".equals(client.get("HEALTH"))) {
|
||||
return Result.unhealthy("fetch failed");
|
||||
}
|
||||
|
||||
return Result.healthy();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user