Class PerfEvent

java.lang.Object
io.karatelabs.core.PerfEvent

public class PerfEvent extends Object
Represents a performance event for Gatling integration.

Events are created after HTTP requests complete, with timing information captured from the request/response cycle. The failed and message fields are mutable so that assertion failures can be attributed to the preceding HTTP request.

  • Constructor Details

    • PerfEvent

      public PerfEvent(long startTime, long endTime, String name, int statusCode)
      Create a new performance event.
      Parameters:
      startTime - request start time in epoch milliseconds
      endTime - request end time in epoch milliseconds
      name - the request name for reporting
      statusCode - the HTTP status code (0 if request failed before response)
  • Method Details

    • getName

      public String getName()
    • getStartTime

      public long getStartTime()
    • getEndTime

      public long getEndTime()
    • getStatusCode

      public int getStatusCode()
    • isFailed

      public boolean isFailed()
    • setFailed

      public void setFailed(boolean failed)
    • getMessage

      public String getMessage()
    • setMessage

      public void setMessage(String message)
    • toString

      public String toString()
      Overrides:
      toString in class Object