Skip to main content

ICkModelImportAuditTrail

Namespace: Meshmakers.Octo.Runtime.Contracts.CkModelMigrations

Records noteworthy events that occur during CK model imports. Bridged at deployment time to the platform notification/event repository via an adapter (analogous to IArchiveAuditTrail); kept as a focused interface so the engine has no direct dependency on the notifications package.

public interface ICkModelImportAuditTrail

Methods

RecordExtensibleEnumValueOverrideAsync(String, CkModelId, CkId<CkEnumId>, String, String, Int32)

Records that a custom extension value of an extensible enum overrode a value defined by the imported CK model with the same key. The custom extension value takes precedence (see WI #3324 acceptance criteria).

Task RecordExtensibleEnumValueOverrideAsync(string tenantId, CkModelId ckModelId, CkId<CkEnumId> ckEnumId, string ckEnumValueName, string extensionValueName, int extensionValueKey)

Parameters

tenantId String
Tenant whose extensible enum was affected. null denotes the system tenant (e.g. import of system models).

ckModelId CkModelId
The CK model that was imported.

ckEnumId CkId<CkEnumId>
The affected extensible enum.

ckEnumValueName String
Name of the CK-defined value that was overridden.

extensionValueName String
Name of the custom extension value that took precedence.

extensionValueKey Int32
Numeric key shared by the CK-defined and the extension value (the cause of the collision).

Returns

Task

RecordWrapScalarInRecordAsync(String, RtCkId<CkTypeId>, OctoObjectId, String, RtCkId<CkRecordId>, Int32, String)

Records that a CK migration WrapScalarInRecord step lifted a populated list attribute from scalar entries to record entries on a runtime entity. Idempotent re-runs (lists that already carry the target record shape) are intentionally NOT recorded — only entities the step actually mutated produce an audit event.

Task RecordWrapScalarInRecordAsync(string tenantId, RtCkId<CkTypeId> ckTypeId, OctoObjectId rtId, string sourceAttribute, RtCkId<CkRecordId> targetRecordCkRecordId, int wrappedCount, string stepId)

Parameters

tenantId String
Tenant whose entity was rewritten. null denotes the system tenant.

ckTypeId RtCkId<CkTypeId>
The CK type of the rewritten entity.

rtId OctoObjectId
The runtime id of the rewritten entity.

sourceAttribute String
The CK attribute id of the list slot that was lifted.

targetRecordCkRecordId RtCkId<CkRecordId>
The CK record id used to wrap each scalar.

wrappedCount Int32
Number of scalar entries wrapped into records during this invocation (entries already in record shape are not counted).

stepId String
Migration step id that drove the rewrite (for traceability).

Returns

Task