IArchiveCoverageInvalidator
Namespace: Meshmakers.Octo.Runtime.Contracts.StreamData
Drops memoised ArchiveCoverage entries (AB#5157) so a coverage answer that a platform operation has just invalidated is re-measured on the next request instead of waiting out the cache TTL.
public interface IArchiveCoverageInvalidator
Remarks:
The platform calls this on the events that change an archive's stored range in a way the TTL
alone would hide for too long. The engine itself owns two of them: an archive delete (that
archive) and the completion of a recompute or backfill job (the recomputed rollup). The
tenant-wide events — dropping a tenant's stream data, or disabling the stream data feature —
happen in the persistence layer and call Invalidate(tenantId) from there. Ordinary
ingest is deliberately not invalidated — it only ever extends the range, and the TTL
absorbs it.
Invalidation is process-local: it clears the cache of the process that observed the event, not of every host in the cluster. Every consumer of this interface treats it as optional (the coverage cache may not be wired at all), so a missing invalidator degrades to TTL-only freshness rather than to an error.
Methods
Invalidate(String, Nullable<OctoObjectId>)
Drops the cached coverage of archiveRtId within
tenantId, or of every archive of that tenant when
archiveRtId is null. Idempotent; a no-op when nothing is cached.
void Invalidate(string tenantId, Nullable<OctoObjectId> archiveRtId)
Parameters
tenantId String
Tenant whose cached coverage is dropped.
archiveRtId Nullable<OctoObjectId>
Archive to drop; null drops the whole tenant.