7b0b9c7365
Solution + 23 src projects + 26 test projects renamed; folders, csproj, namespaces, and ScadaLinkDbContext/ScadaBridgeDbContext class updated. ActorSystem "scadalink" → "scadabridge", Akka seed-node URLs migrated. SQL roles/logins, LDAP domains, CLI command name, and CLI config dir (~/.scadalink → ~/.scadabridge) also renamed. Build green; 5 Host.Tests fail awaiting SQL login rename in next commit. Pre-existing StaleTagMonitor timing flakes unchanged. Rename script committed at tools/rename-to-scadabridge.sh.
42 lines
1.6 KiB
C#
42 lines
1.6 KiB
C#
using System;
|
|
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace ZB.MOM.WW.ScadaBridge.ConfigurationDatabase.Migrations
|
|
{
|
|
/// <summary>
|
|
/// Adds the <c>OriginExecutionId</c> correlation column to the central
|
|
/// <c>Notifications</c> table (#21). It carries the originating script execution's
|
|
/// <c>ExecutionId</c> from the site so the dispatcher can echo it onto the
|
|
/// <c>NotifyDeliver</c> audit rows (#23), linking them to the site's <c>NotifySend</c>
|
|
/// row for the same run.
|
|
///
|
|
/// The change is purely additive: <c>OriginExecutionId uniqueidentifier NULL</c> is
|
|
/// added with no default, so the operation is a metadata-only <c>ALTER TABLE … ADD</c>.
|
|
/// Unlike <c>AuditLog</c>, the <c>Notifications</c> table is NOT partitioned, so a
|
|
/// plain <c>ADD</c> is fine. No index is created — the column is never a query
|
|
/// predicate, only copied onto audit events. Historical rows stay <c>NULL</c>.
|
|
/// </summary>
|
|
public partial class AddNotificationOriginExecutionId : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<Guid>(
|
|
name: "OriginExecutionId",
|
|
table: "Notifications",
|
|
type: "uniqueidentifier",
|
|
nullable: true);
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "OriginExecutionId",
|
|
table: "Notifications");
|
|
}
|
|
}
|
|
}
|