Record Class BatchResult
java.lang.Object
java.lang.Record
org.j7m.middleware.examples.streaming.BatchResult
- Record Components:
accepted- number of accepted itemsrejected- number of rejected itemsbackpressure- whether the session queue reached the configured limit
Result of submitting a batch to the streaming-pipeline example.
-
Constructor Summary
ConstructorsConstructorDescriptionBatchResult(int accepted, int rejected, boolean backpressure) Creates a batch result. -
Method Summary
Modifier and TypeMethodDescriptionintaccepted()Returns the value of theacceptedrecord component.booleanReturns the value of thebackpressurerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intrejected()Returns the value of therejectedrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
BatchResult
public BatchResult(int accepted, int rejected, boolean backpressure) Creates a batch result.- Parameters:
accepted- accepted item countrejected- rejected item countbackpressure- backpressure flag
-
-
Method Details
-
toString
-
hashCode
-
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. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
accepted
-
rejected
-
backpressure
public boolean backpressure()Returns the value of thebackpressurerecord component.- Returns:
- the value of the
backpressurerecord component
-