KlusterKite  0.0.0
A framework to create scalable and redundant services based on awesome Akka.Net project.
KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext > Class Template Referenceabstract

The base class for Entity Framework Code-first migrations More...

Inheritance diagram for KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >:
KlusterKite.NodeManager.Migrator.IMigrator

Public Member Functions

abstract IEnumerable< ResourceIdGetMigratableResources ()
 Gets the list of cluster resources that this migrator can migrate More...
 
abstract ResourceId GetDefaultResourceId ()
 The default resource id to check overall migration parameters More...
 
string GetCurrentPoint (ResourceId resourceId)
 Gets the current configuration migration point for specified resource More...
 
IEnumerable< string > Migrate (ResourceId resourceId, string pointToMigrate)
 Performs the migration procedure More...
 
IEnumerable< string > GetAllPoints ()
 Gets all possible migration points defined in this assembly More...
 

Public Attributes

EnResourceDependencyType DependencyType => EnResourceDependencyType.CodeDependsOnResource
 

Protected Member Functions

 BaseDatabaseMigrator (UniversalContextFactory contextFactory)
 Initializes a new instance of the BaseDatabaseMigrator<TContext> class. More...
 

Properties

string LatestPoint [get]
 
abstract string Name [get]
 
abstract decimal Priority [get]
 
- Properties inherited from KlusterKite.NodeManager.Migrator.IMigrator
string LatestPoint [get]
 Gets the latest known migration point identification for this assembly More...
 
string Name [get]
 Gets the human-readable migrator name More...
 
EnResourceDependencyType DependencyType [get]
 Gets the type of resource dependency More...
 
decimal Priority [get]
 Gets the priority of execution. In case of migration, the migrators will be run in order of priority from largest to lowest More...
 

Detailed Description

The base class for Entity Framework Code-first migrations

Template Parameters
TContextThe type of context
Type Constraints
TContext :DbContext 

Definition at line 25 of file BaseDatabaseMigrator.cs.

Constructor & Destructor Documentation

◆ BaseDatabaseMigrator()

Initializes a new instance of the BaseDatabaseMigrator<TContext> class.

Parameters
contextFactoryThe context factory manager.

Definition at line 39 of file BaseDatabaseMigrator.cs.

Member Function Documentation

◆ GetAllPoints()

IEnumerable<string> KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.GetAllPoints ( )

Gets all possible migration points defined in this assembly

Implements KlusterKite.NodeManager.Migrator.IMigrator.

Definition at line 113 of file BaseDatabaseMigrator.cs.

◆ GetCurrentPoint()

string KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.GetCurrentPoint ( ResourceId  resourceId)

Gets the current configuration migration point for specified resource

Implements KlusterKite.NodeManager.Migrator.IMigrator.

Definition at line 78 of file BaseDatabaseMigrator.cs.

◆ GetDefaultResourceId()

abstract ResourceId KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.GetDefaultResourceId ( )
pure virtual

The default resource id to check overall migration parameters

Returns
The default resource id

Implemented in KlusterKite.NodeManager.ConfigurationSource.ConfigurationMigrator.

◆ GetMigratableResources()

abstract IEnumerable<ResourceId> KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.GetMigratableResources ( )
pure virtual

Gets the list of cluster resources that this migrator can migrate

Implements KlusterKite.NodeManager.Migrator.IMigrator.

Implemented in KlusterKite.NodeManager.ConfigurationSource.ConfigurationMigrator.

◆ Migrate()

IEnumerable<string> KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.Migrate ( ResourceId  resourceId,
string  pointToMigrate 
)

Performs the migration procedure

Implements KlusterKite.NodeManager.Migrator.IMigrator.

Definition at line 88 of file BaseDatabaseMigrator.cs.

Member Data Documentation

◆ DependencyType

Property Documentation

◆ LatestPoint

Definition at line 46 of file BaseDatabaseMigrator.cs.

◆ Name

abstract string KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.Name
get

Definition at line 60 of file BaseDatabaseMigrator.cs.

◆ Priority

abstract decimal KlusterKite.NodeManager.Migrator.EF.BaseDatabaseMigrator< TContext >.Priority
get

Definition at line 66 of file BaseDatabaseMigrator.cs.


The documentation for this class was generated from the following file: