Package org.acemq.workloads.scenario
Record Class ScenarioReport.QueueResult
java.lang.Object
java.lang.Record
org.acemq.workloads.scenario.ScenarioReport.QueueResult
- Record Components:
name- the queuetype- what kind of queue it wasconsumers- how many consumers were on itconsumed- how many messages they handledendToEnd- latency from when a message was due to when it was handleddepthAtStart- what was waiting when measurement begandepthAtEnd- what was waiting when it ended
- Enclosing class:
ScenarioReport
public static record ScenarioReport.QueueResult(String name, QueueType type, int consumers, long consumed, LatencySummary endToEnd, Long depthAtStart, Long depthAtEnd, Expect expectations)
extends Record
What one queue saw.
-
Constructor Summary
ConstructorsConstructorDescriptionQueueResult(String name, QueueType type, int consumers, long consumed, LatencySummary endToEnd, Long depthAtStart, Long depthAtEnd, Expect expectations) Creates an instance of aQueueResultrecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongconsumed()Returns the value of theconsumedrecord component.doubleconsumeRate(Duration duration) intReturns the value of theconsumersrecord component.Returns the value of thedepthAtEndrecord component.Returns the value of thedepthAtStartrecord component.endToEnd()Returns the value of theendToEndrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of theexpectationsrecord component.booleangrew()final inthashCode()Returns a hash code value for this object.name()Returns the value of thenamerecord component.booleanWhether this kind of queue keeps messages after they have been read.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
QueueResult
public QueueResult(String name, QueueType type, int consumers, long consumed, LatencySummary endToEnd, Long depthAtStart, Long depthAtEnd, Expect expectations) Creates an instance of aQueueResultrecord class.- Parameters:
name- the value for thenamerecord componenttype- the value for thetyperecord componentconsumers- the value for theconsumersrecord componentconsumed- the value for theconsumedrecord componentendToEnd- the value for theendToEndrecord componentdepthAtStart- the value for thedepthAtStartrecord componentdepthAtEnd- the value for thedepthAtEndrecord componentexpectations- the value for theexpectationsrecord component
-
-
Method Details
-
retainsMessages
public boolean retainsMessages()Whether this kind of queue keeps messages after they have been read.A stream does: consumers move an offset and nothing is removed, so its "depth" is the length of the log rather than a backlog. Treating that as a backlog reports a stream that kept up perfectly as one whose consumers fell behind, which is exactly backwards and was doing so until this existed.
- Returns:
- whether depth means retention rather than a queue of unhandled work
-
consumeRate
- Parameters:
duration- how long the measured window was- Returns:
- messages a second handled
-
grew
public boolean grew()- Returns:
- whether unhandled work accumulated over the measured window
-
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 '=='. -
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
consumers
public int consumers()Returns the value of theconsumersrecord component.- Returns:
- the value of the
consumersrecord component
-
consumed
public long consumed()Returns the value of theconsumedrecord component.- Returns:
- the value of the
consumedrecord component
-
endToEnd
Returns the value of theendToEndrecord component.- Returns:
- the value of the
endToEndrecord component
-
depthAtStart
Returns the value of thedepthAtStartrecord component.- Returns:
- the value of the
depthAtStartrecord component
-
depthAtEnd
Returns the value of thedepthAtEndrecord component.- Returns:
- the value of the
depthAtEndrecord component
-
expectations
Returns the value of theexpectationsrecord component.- Returns:
- the value of the
expectationsrecord component
-