diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/rest/action/admin/cluster/state/RestClusterStateAction.java b/modules/elasticsearch/src/main/java/org/elasticsearch/rest/action/admin/cluster/state/RestClusterStateAction.java index 9320fef37ee..0454d15ebec 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/rest/action/admin/cluster/state/RestClusterStateAction.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/rest/action/admin/cluster/state/RestClusterStateAction.java @@ -229,7 +229,7 @@ public class RestClusterStateAction extends BaseRestHandler { builder.endArray(); builder.endObject(); } - builder.endObject(); + builder.endArray(); } @@ -252,6 +252,9 @@ public class RestClusterStateAction extends BaseRestHandler { } @Override public void onFailure(Throwable e) { + if (logger.isDebugEnabled()) { + logger.debug("failed to handle cluster state", e); + } try { channel.sendResponse(new XContentThrowableRestResponse(request, e)); } catch (IOException e1) {