java.lang.Object
java.lang.Record
org.elasticsearch.http.HttpStats.ClientStats
- All Implemented Interfaces:
Writeable,ToXContent,ToXContentFragment
- Enclosing class:
HttpStats
public static record HttpStats.ClientStats(int id, String agent, String localAddress, String remoteAddress, String lastUri, String forwardedFor, String opaqueId, long openedTimeMillis, long closedTimeMillis, long lastRequestTimeMillis, long requestCount, long requestSizeBytes)
extends Record
implements Writeable, ToXContentFragment
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsFields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Constructor Summary
ConstructorsConstructorDescriptionClientStats(int id, String agent, String localAddress, String remoteAddress, String lastUri, String forwardedFor, String opaqueId, long openedTimeMillis, long closedTimeMillis, long lastRequestTimeMillis, long requestCount, long requestSizeBytes) Creates an instance of aClientStatsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionagent()Returns the value of theagentrecord component.longReturns the value of theclosedTimeMillisrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theforwardedForrecord component.final inthashCode()Returns a hash code value for this object.intid()Returns the value of theidrecord component.longReturns the value of thelastRequestTimeMillisrecord component.lastUri()Returns the value of thelastUrirecord component.Returns the value of thelocalAddressrecord component.opaqueId()Returns the value of theopaqueIdrecord component.longReturns the value of theopenedTimeMillisrecord component.Returns the value of theremoteAddressrecord component.longReturns the value of therequestCountrecord component.longReturns the value of therequestSizeBytesrecord component.final StringtoString()Returns a string representation of this record class.toXContent(XContentBuilder builder, ToXContent.Params params) voidwriteTo(StreamOutput out) Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentFragment
isFragment
-
Field Details
-
NOT_CLOSED
public static final long NOT_CLOSED- See Also:
-
-
Constructor Details
-
ClientStats
public ClientStats(int id, String agent, String localAddress, String remoteAddress, String lastUri, String forwardedFor, String opaqueId, long openedTimeMillis, long closedTimeMillis, long lastRequestTimeMillis, long requestCount, long requestSizeBytes) Creates an instance of aClientStatsrecord class.- Parameters:
id- the value for theidrecord componentagent- the value for theagentrecord componentlocalAddress- the value for thelocalAddressrecord componentremoteAddress- the value for theremoteAddressrecord componentlastUri- the value for thelastUrirecord componentforwardedFor- the value for theforwardedForrecord componentopaqueId- the value for theopaqueIdrecord componentopenedTimeMillis- the value for theopenedTimeMillisrecord componentclosedTimeMillis- the value for theclosedTimeMillisrecord componentlastRequestTimeMillis- the value for thelastRequestTimeMillisrecord componentrequestCount- the value for therequestCountrecord componentrequestSizeBytes- the value for therequestSizeBytesrecord component
-
-
Method Details
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceToXContent- Throws:
IOException
-
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
id
public int id()Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
agent
Returns the value of theagentrecord component.- Returns:
- the value of the
agentrecord component
-
localAddress
Returns the value of thelocalAddressrecord component.- Returns:
- the value of the
localAddressrecord component
-
remoteAddress
Returns the value of theremoteAddressrecord component.- Returns:
- the value of the
remoteAddressrecord component
-
lastUri
Returns the value of thelastUrirecord component.- Returns:
- the value of the
lastUrirecord component
-
forwardedFor
Returns the value of theforwardedForrecord component.- Returns:
- the value of the
forwardedForrecord component
-
opaqueId
Returns the value of theopaqueIdrecord component.- Returns:
- the value of the
opaqueIdrecord component
-
openedTimeMillis
public long openedTimeMillis()Returns the value of theopenedTimeMillisrecord component.- Returns:
- the value of the
openedTimeMillisrecord component
-
closedTimeMillis
public long closedTimeMillis()Returns the value of theclosedTimeMillisrecord component.- Returns:
- the value of the
closedTimeMillisrecord component
-
lastRequestTimeMillis
public long lastRequestTimeMillis()Returns the value of thelastRequestTimeMillisrecord component.- Returns:
- the value of the
lastRequestTimeMillisrecord component
-
requestCount
public long requestCount()Returns the value of therequestCountrecord component.- Returns:
- the value of the
requestCountrecord component
-
requestSizeBytes
public long requestSizeBytes()Returns the value of therequestSizeBytesrecord component.- Returns:
- the value of the
requestSizeBytesrecord component
-