controller.registerHandler(GET, "/_skywalker/consistencycheck", this);
}
@Override
public void handleRequest(final RestRequest request, final RestChannel channel, final Client client) throws Exception {
ConsistencyCheckRequest r = new ConsistencyCheckRequest();
client.admin().cluster().execute(ConsistencyCheckAction.INSTANCE, r, new RestResponseListener<ConsistencyCheckResponse>(channel) {
@Override
public RestResponse buildResponse(ConsistencyCheckResponse response) throws Exception {
XContentBuilder builder = XContentFactory.jsonBuilder();
builder.startObject();