Interface GatlingStatsReporter


public interface GatlingStatsReporter
Java interface to Gatling's StatsEngine for reporting performance metrics. This allows pure Java code to report metrics without direct Scala dependencies.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    logResponse(String scenario, scala.collection.immutable.List<String> groups, String requestName, long startTime, long endTime, boolean ok, int statusCode, String errorMessage)
    Report a performance event to Gatling's StatsEngine.
    default void
    reportPerfEvent(String scenario, scala.collection.immutable.List<String> groups, io.karatelabs.core.PerfEvent event)
    Convenience method to report a PerfEvent.
  • Method Details

    • logResponse

      void logResponse(String scenario, scala.collection.immutable.List<String> groups, String requestName, long startTime, long endTime, boolean ok, int statusCode, String errorMessage)
      Report a performance event to Gatling's StatsEngine.
      Parameters:
      scenario - the scenario name
      groups - the current groups
      requestName - the request name
      startTime - request start time (epoch ms)
      endTime - request end time (epoch ms)
      ok - true if request succeeded
      statusCode - HTTP status code
      errorMessage - error message (null if ok)
    • reportPerfEvent

      default void reportPerfEvent(String scenario, scala.collection.immutable.List<String> groups, io.karatelabs.core.PerfEvent event)
      Convenience method to report a PerfEvent.