Interface AuditEventPayload

All Known Implementing Classes:
AuditEventPayload.None, DifferentialExpressionAnalysisPayload, ProcessedVectorComputationPayload, ReleaseDetailsUpdatePayload, SampleCorrelationAnalysisPayload, SampleRemovalPayload, SingleCellAggregationPayload, SingleCellSubSetsCreatedPayload

public interface AuditEventPayload
Marker for typed, JSON-serialised payloads carried by an AuditEvent. Implementations are records (one per concrete event type that needs structured per-event data). Each defines its own structural schema directly through its record components; Jackson handles serialisation automatically.

The type discriminator is the record's @JsonTypeName (or its simple class name when @JsonTypeName is absent), stored under the @type property in the serialised JSON. This lets the AUDIT_EVENT.PAYLOAD string be deserialised back to the correct record subtype without compile-time knowledge of which subtype it is, e.g.:

  AuditEventPayload p = objectMapper.readValue(ev.getPayload(), AuditEventPayload.class);
  if (p instanceof BatchInformationFetchingPayload bif) { ... }

Phase A intentionally leaves this interface unsealed: no concrete payload records exist yet outside tests, and the sealed permits list would need to enumerate them. Phase B will tighten this to sealed interface AuditEventPayload permits …, …, … once the record taxonomy is set, at which point Jackson polymorphic deserialisation also benefits from the closed world.

See AUDIT_SYSTEM_AUDIT.md Phase A.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Interface
    Description
    static final record 
    Sentinel payload for events that carry no extra structured data.