diff --git a/src/main/java/org/elasticsearch/action/admin/cluster/stats/ClusterStatsResponse.java b/src/main/java/org/elasticsearch/action/admin/cluster/stats/ClusterStatsResponse.java index 53399f2f3b5..be74ffc48ec 100644 --- a/src/main/java/org/elasticsearch/action/admin/cluster/stats/ClusterStatsResponse.java +++ b/src/main/java/org/elasticsearch/action/admin/cluster/stats/ClusterStatsResponse.java @@ -37,22 +37,27 @@ import java.util.Map; */ public class ClusterStatsResponse extends NodesOperationResponse implements ToXContent { - ClusterStatsNodes nodesStats; ClusterStatsIndices indicesStats; String clusterUUID; + long timestamp; ClusterStatsResponse() { } - public ClusterStatsResponse(ClusterName clusterName, String clusterUUID, ClusterStatsNodeResponse[] nodes) { + public ClusterStatsResponse(long timestamp, ClusterName clusterName, String clusterUUID, ClusterStatsNodeResponse[] nodes) { super(clusterName, null); + this.timestamp = timestamp; this.clusterUUID = clusterUUID; nodesStats = new ClusterStatsNodes(nodes); indicesStats = new ClusterStatsIndices(nodes); } + public long getTimestamp() { + return this.timestamp; + } + public ClusterStatsNodes getNodesStats() { return nodesStats; } @@ -84,6 +89,7 @@ public class ClusterStatsResponse extends NodesOperationResponse