Record Class CaptureNetworkRecorder.RecordedTransaction
java.lang.Object
java.lang.Record
com.shaft.capture.network.CaptureNetworkRecorder.RecordedTransaction
- Record Components:
transactionId- stable identifier correlating request and response evidenceresourceKind- fine-grained resource classificationrequest- sanitized outbound request evidenceresponse- sanitized inbound response evidence, ornullwhen the exchange failed before a response was observedtiming- timing evidence; only the total wall-clock duration is populatedfailureReason- safe failure reason, blank when the exchange completedinitiatorPageUrl- sanitized URL of the page that initiated the transaction
- Enclosing class:
CaptureNetworkRecorder
public static record CaptureNetworkRecorder.RecordedTransaction(String transactionId, ResourceKind resourceKind, HttpRequestRecord request, HttpResponseRecord response, NetworkTiming timing, String failureReason, String initiatorPageUrl)
extends Record
One redacted, replay-safe network transaction observed by this recorder, ready to be
wrapped into a
CaptureEvent.NetworkEvent once the caller assigns an
EventContext (sequence, page, timestamp).-
Constructor Summary
ConstructorsConstructorDescriptionRecordedTransaction(String transactionId, ResourceKind resourceKind, HttpRequestRecord request, HttpResponseRecord response, NetworkTiming timing, String failureReason, String initiatorPageUrl) Creates an instance of aRecordedTransactionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.Returns the value of thefailureReasonrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of theinitiatorPageUrlrecord component.request()Returns the value of therequestrecord component.Returns the value of theresourceKindrecord component.response()Returns the value of theresponserecord component.timing()Returns the value of thetimingrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of thetransactionIdrecord component.
-
Constructor Details
-
RecordedTransaction
public RecordedTransaction(String transactionId, ResourceKind resourceKind, HttpRequestRecord request, HttpResponseRecord response, NetworkTiming timing, String failureReason, String initiatorPageUrl) Creates an instance of aRecordedTransactionrecord class.- Parameters:
transactionId- the value for thetransactionIdrecord componentresourceKind- the value for theresourceKindrecord componentrequest- the value for therequestrecord componentresponse- the value for theresponserecord componenttiming- the value for thetimingrecord componentfailureReason- the value for thefailureReasonrecord componentinitiatorPageUrl- the value for theinitiatorPageUrlrecord component
-
-
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 withObjects::equals(Object,Object). -
transactionId
Returns the value of thetransactionIdrecord component.- Returns:
- the value of the
transactionIdrecord component
-
resourceKind
Returns the value of theresourceKindrecord component.- Returns:
- the value of the
resourceKindrecord component
-
request
-
response
-
timing
-
failureReason
Returns the value of thefailureReasonrecord component.- Returns:
- the value of the
failureReasonrecord component
-
initiatorPageUrl
Returns the value of theinitiatorPageUrlrecord component.- Returns:
- the value of the
initiatorPageUrlrecord component
-