ExtensionMigrationChecks
Namespace: Ankus.PgConfig
Assembly: Ankus.PgConfig.dll
Checks migration fragments as pgrx’s migrate check does: that their dependencies resolve and form no cycle,
that a fragment touching an object another fragment creates declares it, and optionally that fragments keep released
and unreleased changes apart, match an upstream branch, and leave released scripts alone.
public static class ExtensionMigrationChecksInheritance: object
Methods
Section titled “Methods”Render(IReadOnlyList<ExtensionMigrationIssue>, string)
Section titled “Render(IReadOnlyList<ExtensionMigrationIssue>, string)”Formats issues as text, JSON or GitHub annotations.
public static string Render(IReadOnlyList<ExtensionMigrationIssue> issues, string format)Parameters:
issues — IReadOnlyList<ExtensionMigrationIssue>
The issues.
format — string
The format.
Returns: string
The report.
RunAsync(ExtensionMigrationProject, string?, string?, bool, CancellationToken)
Section titled “RunAsync(ExtensionMigrationProject, string?, string?, bool, CancellationToken)”Runs the checks.
public static Task<IReadOnlyList<ExtensionMigrationIssue>> RunAsync(ExtensionMigrationProject project, string? baseReference, string? upstream, bool denyMixedObjects, CancellationToken token)Parameters:
project — ExtensionMigrationProject
The extension’s fragment settings.
baseReference — string
A Git revision: only fragments changed since it are checked, and released scripts it has must be unchanged.
upstream — string
A Git revision every fragment must exist on, byte for byte.
denyMixedObjects — bool
Whether to reject a fragment that mixes released and unreleased objects, or unreleased objects of several prerequisites.
token — CancellationToken
Cancels Git.
Returns: Task<IReadOnlyList<ExtensionMigrationIssue>>
The issues found.