Table of Contents

Class MigrationOptions

Namespace
GroupeIsa.Neos.Migration
Assembly
GroupeIsa.Neos.Migration.Abstractions.dll

Defines the migration options.

[ExcludeFromCodeCoverage(Justification = "Plain old C# object. Dumb class with no behaviors.")]
public record MigrationOptions : IEquatable<MigrationOptions>
Inheritance
MigrationOptions
Implements
Inherited Members

Constructors

MigrationOptions(bool, bool, bool, bool)

Initializes a new instance of the MigrationOptions class.

public MigrationOptions(bool allowDataLoss = false, bool updateExistingDatabase = true, bool force = false, bool dryRun = false)

Parameters

allowDataLoss bool

true to allow data loss; otherwise, false.

updateExistingDatabase bool

When set to true existing database will be migrated. Otherwise, false existing database will not be migrated. If database does not exists, then it will be created even if set to false.

force bool

true to force migration even if the schema version has not changed; otherwise, false.

dryRun bool

true to execute a dry run of the migration; otherwise, false.

Properties

AllowDataLoss

Gets a value indicating whether the migration allows data loss.

public bool AllowDataLoss { get; init; }

Property Value

bool

DryRun

Gets a value indicating whether the migration was a dry run.

public bool DryRun { get; init; }

Property Value

bool

Force

Gets a value indicating whether the migration will be forced.

public bool Force { get; init; }

Property Value

bool

UpdateDatabase

Gets a value indicating whether the migration updates the database.

[Obsolete("Use the UpdateExistingDatabase property instead.", UrlFormat = "https://documentation.neos.groupeisagri.com/api/GroupeIsa.Neos.Migration.MigrationOptions.html")]
public bool UpdateDatabase { get; init; }

Property Value

bool

When set to true database will be migrated. Otherwise, false database will not be migrated. If database does not exists, then it will be created even if set to false.

UpdateExistingDatabase

Gets a value indicating whether the migration updates the existing database.

public bool UpdateExistingDatabase { get; init; }

Property Value

bool

When set to true existing database will be migrated. Otherwise, false existing database will not be migrated. If database does not exists, then it will be created even if set to false.