Record Class ScenarioFile.ConsumersJson

java.lang.Object
java.lang.Record
org.acemq.workloads.scenario.ScenarioFile.ConsumersJson
Record Components:
concurrency - how many consumers
prefetch - how many unacknowledged messages each may hold
handlerTime - how long the handler pretends to work
failureRate - how often it throws, 0 to 1
enabled - whether they run at all
Enclosing class:
ScenarioFile

public static record ScenarioFile.ConsumersJson(Integer concurrency, Integer prefetch, String handlerTime, Double failureRate, Boolean enabled) extends Record
  • Constructor Details

    • ConsumersJson

      public ConsumersJson(Integer concurrency, Integer prefetch, String handlerTime, Double failureRate, Boolean enabled)
      Creates an instance of a ConsumersJson record class.
      Parameters:
      concurrency - the value for the concurrency record component
      prefetch - the value for the prefetch record component
      handlerTime - the value for the handlerTime record component
      failureRate - the value for the failureRate record component
      enabled - the value for the enabled record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • concurrency

      public Integer concurrency()
      Returns the value of the concurrency record component.
      Returns:
      the value of the concurrency record component
    • prefetch

      public Integer prefetch()
      Returns the value of the prefetch record component.
      Returns:
      the value of the prefetch record component
    • handlerTime

      public String handlerTime()
      Returns the value of the handlerTime record component.
      Returns:
      the value of the handlerTime record component
    • failureRate

      public Double failureRate()
      Returns the value of the failureRate record component.
      Returns:
      the value of the failureRate record component
    • enabled

      public Boolean enabled()
      Returns the value of the enabled record component.
      Returns:
      the value of the enabled record component