function

BuildArtifact

Use embedded Atlas planning plus confirmed semantic rename intent to build an immutable migration artifact.

Arguments

ArgumentTypeDescription
ctxcontext.ContextThe ctx value.
namestringThe name value.
before*schema.ManifestThe before value.
afterschema.ManifestThe after value.
optionsArtifactOptionsThe options value.

Returns

The declared result.

(migration.Artifact, error)

How it works

allowDestructive admits reviewed Atlas-confirmed destructive work; some unsafe semantic transitions still fail closed. Prefer ridu migrate create, which records and reviews this contract.

Full signature

func BuildArtifact( ctx context.Context, name string, before *schema.Manifest, after schema.Manifest, options ArtifactOptions, ) (ridumigration.Artifact, error)

Source adapters/postgres/atlas_migration.go:60

Related types

  • Manifest

    An immutable versioned schema contract.

  • ArtifactOptions

    ArtifactOptions are the reviewed decisions a PostgreSQL migration records beyond its before and after manifests.

  • Artifact

    The immutable definition of one migration.