public class ClientHelper extends Object
| Constructor and Description |
|---|
ClientHelper() |
| Modifier and Type | Method and Description |
|---|---|
static String |
clusterName(org.elasticsearch.client.Client client) |
static void |
disableRefresh(org.elasticsearch.client.Client client,
String index) |
static void |
enableRefresh(org.elasticsearch.client.Client client,
String index) |
static void |
flush(org.elasticsearch.client.Client client,
String index) |
static List<String> |
getConnectedNodes(org.elasticsearch.client.transport.TransportClient client) |
static String |
healthColor(org.elasticsearch.client.Client client) |
static void |
refresh(org.elasticsearch.client.Client client,
String index) |
static void |
updateIndexSetting(org.elasticsearch.client.Client client,
String index,
String key,
Object value) |
static int |
updateReplicaLevel(org.elasticsearch.client.Client client,
String index,
int level) |
static void |
waitForCluster(org.elasticsearch.client.Client client,
org.elasticsearch.action.admin.cluster.health.ClusterHealthStatus status,
org.elasticsearch.common.unit.TimeValue timeout) |
static int |
waitForRecovery(org.elasticsearch.client.Client client,
String index) |
public ClientHelper()
public static List<String> getConnectedNodes(org.elasticsearch.client.transport.TransportClient client)
public static void updateIndexSetting(org.elasticsearch.client.Client client, String index, String key, Object value) throws IOException
IOExceptionpublic static int waitForRecovery(org.elasticsearch.client.Client client, String index) throws IOException
IOExceptionpublic static void waitForCluster(org.elasticsearch.client.Client client, org.elasticsearch.action.admin.cluster.health.ClusterHealthStatus status, org.elasticsearch.common.unit.TimeValue timeout) throws IOException
IOExceptionpublic static String clusterName(org.elasticsearch.client.Client client)
public static String healthColor(org.elasticsearch.client.Client client)
public static int updateReplicaLevel(org.elasticsearch.client.Client client, String index, int level) throws IOException
IOExceptionpublic static void disableRefresh(org.elasticsearch.client.Client client, String index) throws IOException
IOExceptionpublic static void enableRefresh(org.elasticsearch.client.Client client, String index) throws IOException
IOExceptionelasticsearch-river-jdbc