Streamable, Writeable, ToXContent, ToXContentFragmentpublic class NodeUsage extends BaseNodeResponse implements ToXContentFragment
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsTransportResponse.EmptyWriteable.Reader<V>, Writeable.Writer<V>EMPTY_PARAMS| Constructor | Description |
|---|---|
NodeUsage(DiscoveryNode node,
long timestamp,
long sinceTime,
java.util.Map<java.lang.String,java.lang.Long> restUsage) |
| Modifier and Type | Method | Description |
|---|---|---|
java.util.Map<java.lang.String,java.lang.Long> |
getRestUsage() |
|
long |
getSinceTime() |
|
long |
getTimestamp() |
|
void |
readFrom(StreamInput in) |
Set this object's fields from a StreamInput.
|
static NodeUsage |
readNodeStats(StreamInput in) |
|
XContentBuilder |
toXContent(XContentBuilder builder,
ToXContent.Params params) |
|
void |
writeTo(StreamOutput out) |
Write this object's fields to a StreamOutput.
|
getNodeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisFragmentremoteAddress, remoteAddresspublic NodeUsage(DiscoveryNode node, long timestamp, long sinceTime, java.util.Map<java.lang.String,java.lang.Long> restUsage)
node - the node these statistics were collected fromtimestamp - the timestamp for when these statistics were collectedsinceTime - the timestamp for when the collection of these statistics
startedrestUsage - a map containing the counts of the number of times each REST
endpoint has been calledpublic static NodeUsage readNodeStats(StreamInput in) throws java.io.IOException
java.io.IOExceptionpublic long getTimestamp()
public long getSinceTime()
public java.util.Map<java.lang.String,java.lang.Long> getRestUsage()
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
toXContent in interface ToXContentjava.io.IOExceptionpublic void readFrom(StreamInput in) throws java.io.IOException
StreamablereadFrom in interface StreamablereadFrom in class BaseNodeResponsejava.io.IOExceptionpublic void writeTo(StreamOutput out) throws java.io.IOException
StreamablewriteTo in interface StreamablewriteTo in interface WriteablewriteTo in class BaseNodeResponsejava.io.IOException