Interface ISchemaUpdater
Signature for component that gets called during startup where the component can detect if the database has correct version as application and possibly execute update scripts.
Namespace: EPiServer.Data.SchemaUpdates
Assembly: EPiServer.Data.dll
Version: 12.0.3Syntax
public interface ISchemaUpdater
Methods
GetStatus(IEnumerable<ConnectionStringOptions>)
Called during startup to collect status of the databases.
Declaration
SchemaStatus GetStatus(IEnumerable<ConnectionStringOptions> connectionStringOptions)
Parameters
Type | Name | Description |
---|---|---|
System. |
connectionStringOptions | The current configured connection strings. |
Returns
Type | Description |
---|---|
Schema |
The handled database and the current version of the database. |
Update(ConnectionStringOptions)
Called during startup if result from GetStatus(IEnumerable<ConnectionStringOptions>) indicates that an update is required.
Declaration
void Update(ConnectionStringOptions connectionStringOptions)
Parameters
Type | Name | Description |
---|---|---|
Connection |
connectionStringOptions | The connection string settings returned from GetStatus(IEnumerable<ConnectionStringOptions>) |
Remarks
An update is considered to be required if the Databasetrue
OR
if the Databasetrue
AND
no ISchemafalse
from method
Is