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.Params
Nested 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 aClientStats
record class. -
Method Summary
Modifier and TypeMethodDescriptionagent()
Returns the value of theagent
record component.long
Returns the value of theclosedTimeMillis
record component.final boolean
Indicates whether some other object is "equal to" this one.Returns the value of theforwardedFor
record component.final int
hashCode()
Returns a hash code value for this object.int
id()
Returns the value of theid
record component.long
Returns the value of thelastRequestTimeMillis
record component.lastUri()
Returns the value of thelastUri
record component.Returns the value of thelocalAddress
record component.opaqueId()
Returns the value of theopaqueId
record component.long
Returns the value of theopenedTimeMillis
record component.Returns the value of theremoteAddress
record component.long
Returns the value of therequestCount
record component.long
Returns the value of therequestSizeBytes
record component.final String
toString()
Returns a string representation of this record class.toXContent
(XContentBuilder builder, ToXContent.Params params) void
writeTo
(StreamOutput out) Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods 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 aClientStats
record class.- Parameters:
id
- the value for theid
record componentagent
- the value for theagent
record componentlocalAddress
- the value for thelocalAddress
record componentremoteAddress
- the value for theremoteAddress
record componentlastUri
- the value for thelastUri
record componentforwardedFor
- the value for theforwardedFor
record componentopaqueId
- the value for theopaqueId
record componentopenedTimeMillis
- the value for theopenedTimeMillis
record componentclosedTimeMillis
- the value for theclosedTimeMillis
record componentlastRequestTimeMillis
- the value for thelastRequestTimeMillis
record componentrequestCount
- the value for therequestCount
record componentrequestSizeBytes
- the value for therequestSizeBytes
record component
-
-
Method Details
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContent
in interfaceToXContent
- Throws:
IOException
-
writeTo
Description copied from interface:Writeable
Write this into the StreamOutput.- Specified by:
writeTo
in 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 theid
record component.- Returns:
- the value of the
id
record component
-
agent
Returns the value of theagent
record component.- Returns:
- the value of the
agent
record component
-
localAddress
Returns the value of thelocalAddress
record component.- Returns:
- the value of the
localAddress
record component
-
remoteAddress
Returns the value of theremoteAddress
record component.- Returns:
- the value of the
remoteAddress
record component
-
lastUri
Returns the value of thelastUri
record component.- Returns:
- the value of the
lastUri
record component
-
forwardedFor
Returns the value of theforwardedFor
record component.- Returns:
- the value of the
forwardedFor
record component
-
opaqueId
Returns the value of theopaqueId
record component.- Returns:
- the value of the
opaqueId
record component
-
openedTimeMillis
public long openedTimeMillis()Returns the value of theopenedTimeMillis
record component.- Returns:
- the value of the
openedTimeMillis
record component
-
closedTimeMillis
public long closedTimeMillis()Returns the value of theclosedTimeMillis
record component.- Returns:
- the value of the
closedTimeMillis
record component
-
lastRequestTimeMillis
public long lastRequestTimeMillis()Returns the value of thelastRequestTimeMillis
record component.- Returns:
- the value of the
lastRequestTimeMillis
record component
-
requestCount
public long requestCount()Returns the value of therequestCount
record component.- Returns:
- the value of the
requestCount
record component
-
requestSizeBytes
public long requestSizeBytes()Returns the value of therequestSizeBytes
record component.- Returns:
- the value of the
requestSizeBytes
record component
-