Interface IMigration
An explicit, ordered, imperative migration — for data transforms, seeds, and semantic schema changes that the declarative CRC-gated sync cannot express. Discovered by registration or assembly scan and run by the MigrationRunner in Version order.
public interface IMigration
Properties
Description
Human-readable description recorded in the __migrations history.
string Description { get; }
Property Value
Version
The migration's ordered position.
MigrationVersion Version { get; }
Property Value
Methods
DownAsync(IMigrationContext, CancellationToken)
Reverts the migration. Override to enable rollback; the default Migration base throws NotSupportedException.
Task DownAsync(IMigrationContext ctx, CancellationToken ct)
Parameters
Returns
UpAsync(IMigrationContext, CancellationToken)
Applies the migration. Runs inside a transaction owned by the runner.
Task UpAsync(IMigrationContext ctx, CancellationToken ct)