Record Class RequestExplanation.ForwardFailure

java.lang.Object
java.lang.Record
org.mockserver.client.RequestExplanation.ForwardFailure
Record Components:
statusCode - the status MockServer answered with, or null
reason - why the forward failed, redacted as the event log is and capped at 2048 characters
reasonTruncated - whether reason was capped
causeNamed - whether MockServer named the cause (when false the reason is the raw error), or null
forwardLoopSuspected - whether the forward appears to have gone back to MockServer itself, or null
hint - what to look at next, or null; sent when causeNamed is false
Enclosing class:
RequestExplanation

public static record RequestExplanation.ForwardFailure(Integer statusCode, String reason, boolean reasonTruncated, Boolean causeNamed, Boolean forwardLoopSuspected, String hint) extends Record
The request was forwarded and the forward failed, so MockServer answered with a 502.
  • Constructor Details

    • ForwardFailure

      public ForwardFailure(Integer statusCode, String reason, boolean reasonTruncated, Boolean causeNamed, Boolean forwardLoopSuspected, String hint)
      Creates an instance of a ForwardFailure record class.
      Parameters:
      statusCode - the value for the statusCode record component
      reason - the value for the reason record component
      reasonTruncated - the value for the reasonTruncated record component
      causeNamed - the value for the causeNamed record component
      forwardLoopSuspected - the value for the forwardLoopSuspected record component
      hint - the value for the hint 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • statusCode

      public Integer statusCode()
      Returns the value of the statusCode record component.
      Returns:
      the value of the statusCode record component
    • reason

      public String reason()
      Returns the value of the reason record component.
      Returns:
      the value of the reason record component
    • reasonTruncated

      public boolean reasonTruncated()
      Returns the value of the reasonTruncated record component.
      Returns:
      the value of the reasonTruncated record component
    • causeNamed

      public Boolean causeNamed()
      Returns the value of the causeNamed record component.
      Returns:
      the value of the causeNamed record component
    • forwardLoopSuspected

      public Boolean forwardLoopSuspected()
      Returns the value of the forwardLoopSuspected record component.
      Returns:
      the value of the forwardLoopSuspected record component
    • hint

      public String hint()
      Returns the value of the hint record component.
      Returns:
      the value of the hint record component