Class AuditStore

java.lang.Object
org.mockserver.mock.audit.AuditStore

public class AuditStore extends Object
Thread-safe, append-only, bounded ring buffer of AuditEntry records for control-plane mutations. Oldest entries are evicted once the store reaches its maximum capacity.

The singleton's capacity is fixed at construction (read once from controlPlaneAuditMaxEntries), mirroring DriftStore. A package-visible constructor exists for unit tests that need an isolated, small-capacity instance.

  • Method Details

    • getInstance

      public static AuditStore getInstance()
    • add

      public void add(AuditEntry entry)
    • getRecent

      public List<AuditEntry> getRecent(int limit)
      Returns up to limit most-recent entries, newest first.
    • clear

      public void clear()
    • size

      public int size()