< Summary

Line coverage
0%
Covered lines: 0
Uncovered lines: 701
Coverable lines: 701
Total lines: 775
Line coverage: 0%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
File 1: .ctor(...)100%210%
File 1: Up(...)100%210%
File 1: Down(...)100%210%
File 2: BuildTargetModel(...)100%210%

File(s)

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Persistence.EFCore.PostgreSql/Migrations/Runtime/20260520121653_V3_8.cs

#LineLine coverage
 1using System;
 2using Microsoft.EntityFrameworkCore.Migrations;
 3
 4#nullable disable
 5
 6namespace Elsa.Persistence.EFCore.PostgreSql.Migrations.Runtime
 7{
 8    /// <inheritdoc />
 9    public partial class V3_8 : Migration
 10    {
 11        private readonly Elsa.Persistence.EFCore.IElsaDbContextSchema _schema;
 12
 13        /// <inheritdoc />
 014        public V3_8(Elsa.Persistence.EFCore.IElsaDbContextSchema schema)
 15        {
 016            _schema = schema;
 017        }
 18
 19        /// <inheritdoc />
 20        protected override void Up(MigrationBuilder migrationBuilder)
 21        {
 022            migrationBuilder.AddColumn<int>(
 023                name: "DeliveryAttempts",
 024                schema: _schema.Schema,
 025                table: "BookmarkQueueItems",
 026                type: "integer",
 027                nullable: false,
 028                defaultValue: 0);
 29
 030            migrationBuilder.AddColumn<DateTimeOffset>(
 031                name: "LastAttemptedAt",
 032                schema: _schema.Schema,
 033                table: "BookmarkQueueItems",
 034                type: "timestamp with time zone",
 035                nullable: true);
 36
 037            migrationBuilder.AddColumn<string>(
 038                name: "LastErrorMessage",
 039                schema: _schema.Schema,
 040                table: "BookmarkQueueItems",
 041                type: "text",
 042                nullable: true);
 43
 044            migrationBuilder.AddColumn<string>(
 045                name: "LastErrorType",
 046                schema: _schema.Schema,
 047                table: "BookmarkQueueItems",
 048                type: "text",
 049                nullable: true);
 50
 051            migrationBuilder.CreateTable(
 052                name: "BookmarkQueueDeadLetterItems",
 053                schema: _schema.Schema,
 054                columns: table => new
 055                {
 056                    Id = table.Column<string>(type: "text", nullable: false),
 057                    OriginalQueueItemId = table.Column<string>(type: "text", nullable: false),
 058                    WorkflowInstanceId = table.Column<string>(type: "text", nullable: true),
 059                    CorrelationId = table.Column<string>(type: "text", nullable: true),
 060                    BookmarkId = table.Column<string>(type: "text", nullable: true),
 061                    StimulusHash = table.Column<string>(type: "text", nullable: true),
 062                    ActivityInstanceId = table.Column<string>(type: "text", nullable: true),
 063                    ActivityTypeName = table.Column<string>(type: "text", nullable: true),
 064                    OriginalCreatedAt = table.Column<DateTimeOffset>(type: "timestamp with time zone", nullable: false),
 065                    DeadLetteredAt = table.Column<DateTimeOffset>(type: "timestamp with time zone", nullable: false),
 066                    Reason = table.Column<string>(type: "text", nullable: false),
 067                    DeliveryAttempts = table.Column<int>(type: "integer", nullable: false),
 068                    LastAttemptedAt = table.Column<DateTimeOffset>(type: "timestamp with time zone", nullable: true),
 069                    LastErrorType = table.Column<string>(type: "text", nullable: true),
 070                    LastErrorMessage = table.Column<string>(type: "text", nullable: true),
 071                    CanReplay = table.Column<bool>(type: "boolean", nullable: false),
 072                    ReplayedAt = table.Column<DateTimeOffset>(type: "timestamp with time zone", nullable: true),
 073                    ReplayedQueueItemId = table.Column<string>(type: "text", nullable: true),
 074                    SerializedOptions = table.Column<string>(type: "text", nullable: true),
 075                    TenantId = table.Column<string>(type: "text", nullable: true)
 076                },
 077                constraints: table =>
 078                {
 079                    table.PrimaryKey("PK_BookmarkQueueDeadLetterItems", x => x.Id);
 080                });
 81
 082            migrationBuilder.CreateIndex(
 083                name: "IX_BookmarkQueueDeadLetterItem_ActivityInstanceId",
 084                schema: _schema.Schema,
 085                table: "BookmarkQueueDeadLetterItems",
 086                column: "ActivityInstanceId");
 87
 088            migrationBuilder.CreateIndex(
 089                name: "IX_BookmarkQueueDeadLetterItem_ActivityTypeName",
 090                schema: _schema.Schema,
 091                table: "BookmarkQueueDeadLetterItems",
 092                column: "ActivityTypeName");
 93
 094            migrationBuilder.CreateIndex(
 095                name: "IX_BookmarkQueueDeadLetterItem_BookmarkId",
 096                schema: _schema.Schema,
 097                table: "BookmarkQueueDeadLetterItems",
 098                column: "BookmarkId");
 99
 0100            migrationBuilder.CreateIndex(
 0101                name: "IX_BookmarkQueueDeadLetterItem_CorrelationId",
 0102                schema: _schema.Schema,
 0103                table: "BookmarkQueueDeadLetterItems",
 0104                column: "CorrelationId");
 105
 0106            migrationBuilder.CreateIndex(
 0107                name: "IX_BookmarkQueueDeadLetterItem_DeadLetteredAt",
 0108                schema: _schema.Schema,
 0109                table: "BookmarkQueueDeadLetterItems",
 0110                column: "DeadLetteredAt");
 111
 0112            migrationBuilder.CreateIndex(
 0113                name: "IX_BookmarkQueueDeadLetterItem_OriginalQueueItemId",
 0114                schema: _schema.Schema,
 0115                table: "BookmarkQueueDeadLetterItems",
 0116                column: "OriginalQueueItemId",
 0117                unique: true);
 118
 0119            migrationBuilder.CreateIndex(
 0120                name: "IX_BookmarkQueueDeadLetterItem_TenantId",
 0121                schema: _schema.Schema,
 0122                table: "BookmarkQueueDeadLetterItems",
 0123                column: "TenantId");
 124
 0125            migrationBuilder.CreateIndex(
 0126                name: "IX_BookmarkQueueDeadLetterItem_WorkflowInstanceId",
 0127                schema: _schema.Schema,
 0128                table: "BookmarkQueueDeadLetterItems",
 0129                column: "WorkflowInstanceId");
 0130        }
 131
 132        /// <inheritdoc />
 133        protected override void Down(MigrationBuilder migrationBuilder)
 134        {
 0135            migrationBuilder.DropTable(
 0136                name: "BookmarkQueueDeadLetterItems",
 0137                schema: _schema.Schema);
 138
 0139            migrationBuilder.DropColumn(
 0140                name: "DeliveryAttempts",
 0141                schema: _schema.Schema,
 0142                table: "BookmarkQueueItems");
 143
 0144            migrationBuilder.DropColumn(
 0145                name: "LastAttemptedAt",
 0146                schema: _schema.Schema,
 0147                table: "BookmarkQueueItems");
 148
 0149            migrationBuilder.DropColumn(
 0150                name: "LastErrorMessage",
 0151                schema: _schema.Schema,
 0152                table: "BookmarkQueueItems");
 153
 0154            migrationBuilder.DropColumn(
 0155                name: "LastErrorType",
 0156                schema: _schema.Schema,
 0157                table: "BookmarkQueueItems");
 158
 0159        }
 160    }
 161}

/home/runner/work/elsa-core/elsa-core/src/modules/Elsa.Persistence.EFCore.PostgreSql/Migrations/Runtime/20260520121653_V3_8.Designer.cs

#LineLine coverage
 1// <auto-generated />
 2using System;
 3using Elsa.Persistence.EFCore.Modules.Runtime;
 4using Microsoft.EntityFrameworkCore;
 5using Microsoft.EntityFrameworkCore.Infrastructure;
 6using Microsoft.EntityFrameworkCore.Migrations;
 7using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
 8using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
 9
 10#nullable disable
 11
 12namespace Elsa.Persistence.EFCore.PostgreSql.Migrations.Runtime
 13{
 14    [DbContext(typeof(RuntimeElsaDbContext))]
 15    [Migration("20260520121653_V3_8")]
 16    partial class V3_8
 17    {
 18        /// <inheritdoc />
 19        protected override void BuildTargetModel(ModelBuilder modelBuilder)
 20        {
 21#pragma warning disable 612, 618
 022            modelBuilder
 023                .HasDefaultSchema("Elsa")
 024                .HasAnnotation("ProductVersion", "9.0.11")
 025                .HasAnnotation("Relational:MaxIdentifierLength", 63);
 26
 027            NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
 28
 029            modelBuilder.Entity("Elsa.KeyValues.Entities.SerializedKeyValuePair", b =>
 030                {
 031                    b.Property<string>("Id")
 032                        .HasColumnType("text");
 033
 034                    b.Property<string>("SerializedValue")
 035                        .IsRequired()
 036                        .HasColumnType("text");
 037
 038                    b.Property<string>("TenantId")
 039                        .HasColumnType("text");
 040
 041                    b.HasKey("Id");
 042
 043                    b.HasIndex(new[] { "TenantId" }, "IX_SerializedKeyValuePair_TenantId");
 044
 045                    b.ToTable("KeyValuePairs", "Elsa");
 046                });
 47
 048            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.ActivityExecutionRecord", b =>
 049                {
 050                    b.Property<string>("Id")
 051                        .HasColumnType("text");
 052
 053                    b.Property<string>("ActivityId")
 054                        .IsRequired()
 055                        .HasColumnType("text");
 056
 057                    b.Property<string>("ActivityName")
 058                        .HasColumnType("text");
 059
 060                    b.Property<string>("ActivityNodeId")
 061                        .IsRequired()
 062                        .HasColumnType("text");
 063
 064                    b.Property<string>("ActivityType")
 065                        .IsRequired()
 066                        .HasColumnType("text");
 067
 068                    b.Property<int>("ActivityTypeVersion")
 069                        .HasColumnType("integer");
 070
 071                    b.Property<int>("AggregateFaultCount")
 072                        .HasColumnType("integer");
 073
 074                    b.Property<int?>("CallStackDepth")
 075                        .HasColumnType("integer");
 076
 077                    b.Property<DateTimeOffset?>("CompletedAt")
 078                        .HasColumnType("timestamp with time zone");
 079
 080                    b.Property<bool>("HasBookmarks")
 081                        .HasColumnType("boolean");
 082
 083                    b.Property<string>("SchedulingActivityExecutionId")
 084                        .HasColumnType("text");
 085
 086                    b.Property<string>("SchedulingActivityId")
 087                        .HasColumnType("text");
 088
 089                    b.Property<string>("SchedulingWorkflowInstanceId")
 090                        .HasColumnType("text");
 091
 092                    b.Property<string>("SerializedActivityState")
 093                        .HasColumnType("text");
 094
 095                    b.Property<string>("SerializedActivityStateCompressionAlgorithm")
 096                        .HasColumnType("text");
 097
 098                    b.Property<string>("SerializedException")
 099                        .HasColumnType("text");
 0100
 0101                    b.Property<string>("SerializedMetadata")
 0102                        .HasColumnType("text");
 0103
 0104                    b.Property<string>("SerializedOutputs")
 0105                        .HasColumnType("text");
 0106
 0107                    b.Property<string>("SerializedPayload")
 0108                        .HasColumnType("text");
 0109
 0110                    b.Property<string>("SerializedProperties")
 0111                        .HasColumnType("text");
 0112
 0113                    b.Property<DateTimeOffset>("StartedAt")
 0114                        .HasColumnType("timestamp with time zone");
 0115
 0116                    b.Property<string>("Status")
 0117                        .IsRequired()
 0118                        .HasColumnType("text");
 0119
 0120                    b.Property<string>("TenantId")
 0121                        .HasColumnType("text");
 0122
 0123                    b.Property<string>("WorkflowInstanceId")
 0124                        .IsRequired()
 0125                        .HasColumnType("text");
 0126
 0127                    b.HasKey("Id");
 0128
 0129                    b.HasIndex("ActivityId")
 0130                        .HasDatabaseName("IX_ActivityExecutionRecord_ActivityId");
 0131
 0132                    b.HasIndex("ActivityName")
 0133                        .HasDatabaseName("IX_ActivityExecutionRecord_ActivityName");
 0134
 0135                    b.HasIndex("ActivityType")
 0136                        .HasDatabaseName("IX_ActivityExecutionRecord_ActivityType");
 0137
 0138                    b.HasIndex("ActivityTypeVersion")
 0139                        .HasDatabaseName("IX_ActivityExecutionRecord_ActivityTypeVersion");
 0140
 0141                    b.HasIndex("CompletedAt")
 0142                        .HasDatabaseName("IX_ActivityExecutionRecord_CompletedAt");
 0143
 0144                    b.HasIndex("HasBookmarks")
 0145                        .HasDatabaseName("IX_ActivityExecutionRecord_HasBookmarks");
 0146
 0147                    b.HasIndex("StartedAt")
 0148                        .HasDatabaseName("IX_ActivityExecutionRecord_StartedAt");
 0149
 0150                    b.HasIndex("Status")
 0151                        .HasDatabaseName("IX_ActivityExecutionRecord_Status");
 0152
 0153                    b.HasIndex("TenantId")
 0154                        .HasDatabaseName("IX_ActivityExecutionRecord_TenantId");
 0155
 0156                    b.HasIndex("WorkflowInstanceId")
 0157                        .HasDatabaseName("IX_ActivityExecutionRecord_WorkflowInstanceId");
 0158
 0159                    b.HasIndex("ActivityType", "ActivityTypeVersion")
 0160                        .HasDatabaseName("IX_ActivityExecutionRecord_ActivityType_ActivityTypeVersion");
 0161
 0162                    b.ToTable("ActivityExecutionRecords", "Elsa");
 0163                });
 164
 0165            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.BookmarkQueueDeadLetterItem", b =>
 0166                {
 0167                    b.Property<string>("Id")
 0168                        .HasColumnType("text");
 0169
 0170                    b.Property<string>("ActivityInstanceId")
 0171                        .HasColumnType("text");
 0172
 0173                    b.Property<string>("ActivityTypeName")
 0174                        .HasColumnType("text");
 0175
 0176                    b.Property<string>("BookmarkId")
 0177                        .HasColumnType("text");
 0178
 0179                    b.Property<bool>("CanReplay")
 0180                        .HasColumnType("boolean");
 0181
 0182                    b.Property<string>("CorrelationId")
 0183                        .HasColumnType("text");
 0184
 0185                    b.Property<DateTimeOffset>("DeadLetteredAt")
 0186                        .HasColumnType("timestamp with time zone");
 0187
 0188                    b.Property<int>("DeliveryAttempts")
 0189                        .HasColumnType("integer");
 0190
 0191                    b.Property<DateTimeOffset?>("LastAttemptedAt")
 0192                        .HasColumnType("timestamp with time zone");
 0193
 0194                    b.Property<string>("LastErrorMessage")
 0195                        .HasColumnType("text");
 0196
 0197                    b.Property<string>("LastErrorType")
 0198                        .HasColumnType("text");
 0199
 0200                    b.Property<DateTimeOffset>("OriginalCreatedAt")
 0201                        .HasColumnType("timestamp with time zone");
 0202
 0203                    b.Property<string>("OriginalQueueItemId")
 0204                        .IsRequired()
 0205                        .HasColumnType("text");
 0206
 0207                    b.Property<string>("Reason")
 0208                        .IsRequired()
 0209                        .HasColumnType("text");
 0210
 0211                    b.Property<DateTimeOffset?>("ReplayedAt")
 0212                        .HasColumnType("timestamp with time zone");
 0213
 0214                    b.Property<string>("ReplayedQueueItemId")
 0215                        .HasColumnType("text");
 0216
 0217                    b.Property<string>("SerializedOptions")
 0218                        .HasColumnType("text");
 0219
 0220                    b.Property<string>("StimulusHash")
 0221                        .HasColumnType("text");
 0222
 0223                    b.Property<string>("TenantId")
 0224                        .HasColumnType("text");
 0225
 0226                    b.Property<string>("WorkflowInstanceId")
 0227                        .HasColumnType("text");
 0228
 0229                    b.HasKey("Id");
 0230
 0231                    b.HasIndex(new[] { "ActivityInstanceId" }, "IX_BookmarkQueueDeadLetterItem_ActivityInstanceId");
 0232
 0233                    b.HasIndex(new[] { "ActivityTypeName" }, "IX_BookmarkQueueDeadLetterItem_ActivityTypeName");
 0234
 0235                    b.HasIndex(new[] { "BookmarkId" }, "IX_BookmarkQueueDeadLetterItem_BookmarkId");
 0236
 0237                    b.HasIndex(new[] { "CorrelationId" }, "IX_BookmarkQueueDeadLetterItem_CorrelationId");
 0238
 0239                    b.HasIndex(new[] { "DeadLetteredAt" }, "IX_BookmarkQueueDeadLetterItem_DeadLetteredAt");
 0240
 0241                    b.HasIndex(new[] { "OriginalQueueItemId" }, "IX_BookmarkQueueDeadLetterItem_OriginalQueueItemId")
 0242                        .IsUnique();
 0243
 0244                    b.HasIndex(new[] { "TenantId" }, "IX_BookmarkQueueDeadLetterItem_TenantId");
 0245
 0246                    b.HasIndex(new[] { "WorkflowInstanceId" }, "IX_BookmarkQueueDeadLetterItem_WorkflowInstanceId");
 0247
 0248                    b.ToTable("BookmarkQueueDeadLetterItems", "Elsa");
 0249                });
 250
 0251            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.BookmarkQueueItem", b =>
 0252                {
 0253                    b.Property<string>("Id")
 0254                        .HasColumnType("text");
 0255
 0256                    b.Property<string>("ActivityInstanceId")
 0257                        .HasColumnType("text");
 0258
 0259                    b.Property<string>("ActivityTypeName")
 0260                        .HasColumnType("text");
 0261
 0262                    b.Property<string>("BookmarkId")
 0263                        .HasColumnType("text");
 0264
 0265                    b.Property<string>("CorrelationId")
 0266                        .HasColumnType("text");
 0267
 0268                    b.Property<DateTimeOffset>("CreatedAt")
 0269                        .HasColumnType("timestamp with time zone");
 0270
 0271                    b.Property<int>("DeliveryAttempts")
 0272                        .HasColumnType("integer");
 0273
 0274                    b.Property<DateTimeOffset?>("LastAttemptedAt")
 0275                        .HasColumnType("timestamp with time zone");
 0276
 0277                    b.Property<string>("LastErrorMessage")
 0278                        .HasColumnType("text");
 0279
 0280                    b.Property<string>("LastErrorType")
 0281                        .HasColumnType("text");
 0282
 0283                    b.Property<string>("SerializedOptions")
 0284                        .HasColumnType("text");
 0285
 0286                    b.Property<string>("StimulusHash")
 0287                        .HasColumnType("text");
 0288
 0289                    b.Property<string>("TenantId")
 0290                        .HasColumnType("text");
 0291
 0292                    b.Property<string>("WorkflowInstanceId")
 0293                        .HasColumnType("text");
 0294
 0295                    b.HasKey("Id");
 0296
 0297                    b.HasIndex(new[] { "ActivityInstanceId" }, "IX_BookmarkQueueItem_ActivityInstanceId");
 0298
 0299                    b.HasIndex(new[] { "ActivityTypeName" }, "IX_BookmarkQueueItem_ActivityTypeName");
 0300
 0301                    b.HasIndex(new[] { "BookmarkId" }, "IX_BookmarkQueueItem_BookmarkId");
 0302
 0303                    b.HasIndex(new[] { "CorrelationId" }, "IX_BookmarkQueueItem_CorrelationId");
 0304
 0305                    b.HasIndex(new[] { "CreatedAt" }, "IX_BookmarkQueueItem_CreatedAt");
 0306
 0307                    b.HasIndex(new[] { "StimulusHash" }, "IX_BookmarkQueueItem_StimulusHash");
 0308
 0309                    b.HasIndex(new[] { "TenantId" }, "IX_BookmarkQueueItem_TenantId");
 0310
 0311                    b.HasIndex(new[] { "WorkflowInstanceId" }, "IX_BookmarkQueueItem_WorkflowInstanceId");
 0312
 0313                    b.ToTable("BookmarkQueueItems", "Elsa");
 0314                });
 315
 0316            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.StoredBookmark", b =>
 0317                {
 0318                    b.Property<string>("Id")
 0319                        .HasColumnType("text");
 0320
 0321                    b.Property<string>("ActivityInstanceId")
 0322                        .HasColumnType("text");
 0323
 0324                    b.Property<string>("ActivityTypeName")
 0325                        .IsRequired()
 0326                        .HasColumnType("text");
 0327
 0328                    b.Property<string>("CorrelationId")
 0329                        .HasColumnType("text");
 0330
 0331                    b.Property<DateTimeOffset>("CreatedAt")
 0332                        .HasColumnType("timestamp with time zone");
 0333
 0334                    b.Property<string>("Hash")
 0335                        .IsRequired()
 0336                        .HasColumnType("text");
 0337
 0338                    b.Property<string>("Name")
 0339                        .HasColumnType("text");
 0340
 0341                    b.Property<string>("SerializedMetadata")
 0342                        .HasColumnType("text");
 0343
 0344                    b.Property<string>("SerializedPayload")
 0345                        .HasColumnType("text");
 0346
 0347                    b.Property<string>("TenantId")
 0348                        .HasColumnType("text");
 0349
 0350                    b.Property<string>("WorkflowInstanceId")
 0351                        .IsRequired()
 0352                        .HasColumnType("text");
 0353
 0354                    b.HasKey("Id");
 0355
 0356                    b.HasIndex(new[] { "ActivityInstanceId" }, "IX_StoredBookmark_ActivityInstanceId");
 0357
 0358                    b.HasIndex(new[] { "ActivityTypeName" }, "IX_StoredBookmark_ActivityTypeName");
 0359
 0360                    b.HasIndex(new[] { "ActivityTypeName", "Hash" }, "IX_StoredBookmark_ActivityTypeName_Hash");
 0361
 0362                    b.HasIndex(new[] { "ActivityTypeName", "Hash", "WorkflowInstanceId" }, "IX_StoredBookmark_ActivityTy
 0363
 0364                    b.HasIndex(new[] { "CreatedAt" }, "IX_StoredBookmark_CreatedAt");
 0365
 0366                    b.HasIndex(new[] { "Hash" }, "IX_StoredBookmark_Hash");
 0367
 0368                    b.HasIndex(new[] { "Name" }, "IX_StoredBookmark_Name");
 0369
 0370                    b.HasIndex(new[] { "Name", "Hash" }, "IX_StoredBookmark_Name_Hash");
 0371
 0372                    b.HasIndex(new[] { "Name", "Hash", "WorkflowInstanceId" }, "IX_StoredBookmark_Name_Hash_WorkflowInst
 0373
 0374                    b.HasIndex(new[] { "TenantId" }, "IX_StoredBookmark_TenantId");
 0375
 0376                    b.HasIndex(new[] { "WorkflowInstanceId" }, "IX_StoredBookmark_WorkflowInstanceId");
 0377
 0378                    b.ToTable("Bookmarks", "Elsa");
 0379                });
 380
 0381            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.StoredTrigger", b =>
 0382                {
 0383                    b.Property<string>("Id")
 0384                        .HasColumnType("text");
 0385
 0386                    b.Property<string>("ActivityId")
 0387                        .IsRequired()
 0388                        .HasColumnType("text");
 0389
 0390                    b.Property<string>("Hash")
 0391                        .HasColumnType("text");
 0392
 0393                    b.Property<string>("Name")
 0394                        .HasColumnType("text");
 0395
 0396                    b.Property<string>("SerializedPayload")
 0397                        .HasColumnType("text");
 0398
 0399                    b.Property<string>("TenantId")
 0400                        .HasColumnType("text");
 0401
 0402                    b.Property<string>("WorkflowDefinitionId")
 0403                        .IsRequired()
 0404                        .HasColumnType("text");
 0405
 0406                    b.Property<string>("WorkflowDefinitionVersionId")
 0407                        .IsRequired()
 0408                        .HasColumnType("text");
 0409
 0410                    b.HasKey("Id");
 0411
 0412                    b.HasIndex("Hash")
 0413                        .HasDatabaseName("IX_StoredTrigger_Hash");
 0414
 0415                    b.HasIndex("Name")
 0416                        .HasDatabaseName("IX_StoredTrigger_Name");
 0417
 0418                    b.HasIndex("TenantId")
 0419                        .HasDatabaseName("IX_StoredTrigger_TenantId");
 0420
 0421                    b.HasIndex("WorkflowDefinitionId")
 0422                        .HasDatabaseName("IX_StoredTrigger_WorkflowDefinitionId");
 0423
 0424                    b.HasIndex("WorkflowDefinitionVersionId")
 0425                        .HasDatabaseName("IX_StoredTrigger_WorkflowDefinitionVersionId");
 0426
 0427                    b.HasIndex("WorkflowDefinitionId", "Hash", "ActivityId")
 0428                        .IsUnique()
 0429                        .HasDatabaseName("IX_StoredTrigger_Unique_WorkflowDefinitionId_Hash_ActivityId");
 0430
 0431                    b.ToTable("Triggers", "Elsa");
 0432                });
 433
 0434            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.WorkflowExecutionLogRecord", b =>
 0435                {
 0436                    b.Property<string>("Id")
 0437                        .HasColumnType("text");
 0438
 0439                    b.Property<string>("ActivityId")
 0440                        .IsRequired()
 0441                        .HasColumnType("text");
 0442
 0443                    b.Property<string>("ActivityInstanceId")
 0444                        .IsRequired()
 0445                        .HasColumnType("text");
 0446
 0447                    b.Property<string>("ActivityName")
 0448                        .HasColumnType("text");
 0449
 0450                    b.Property<string>("ActivityNodeId")
 0451                        .IsRequired()
 0452                        .HasColumnType("text");
 0453
 0454                    b.Property<string>("ActivityType")
 0455                        .IsRequired()
 0456                        .HasColumnType("text");
 0457
 0458                    b.Property<int>("ActivityTypeVersion")
 0459                        .HasColumnType("integer");
 0460
 0461                    b.Property<string>("EventName")
 0462                        .HasColumnType("text");
 0463
 0464                    b.Property<string>("Message")
 0465                        .HasColumnType("text");
 0466
 0467                    b.Property<string>("ParentActivityInstanceId")
 0468                        .HasColumnType("text");
 0469
 0470                    b.Property<long>("Sequence")
 0471                        .HasColumnType("bigint");
 0472
 0473                    b.Property<string>("SerializedActivityState")
 0474                        .HasColumnType("text");
 0475
 0476                    b.Property<string>("SerializedPayload")
 0477                        .HasColumnType("text");
 0478
 0479                    b.Property<string>("Source")
 0480                        .HasColumnType("text");
 0481
 0482                    b.Property<string>("TenantId")
 0483                        .HasColumnType("text");
 0484
 0485                    b.Property<DateTimeOffset>("Timestamp")
 0486                        .HasColumnType("timestamp with time zone");
 0487
 0488                    b.Property<string>("WorkflowDefinitionId")
 0489                        .IsRequired()
 0490                        .HasColumnType("text");
 0491
 0492                    b.Property<string>("WorkflowDefinitionVersionId")
 0493                        .IsRequired()
 0494                        .HasColumnType("text");
 0495
 0496                    b.Property<string>("WorkflowInstanceId")
 0497                        .IsRequired()
 0498                        .HasColumnType("text");
 0499
 0500                    b.Property<int>("WorkflowVersion")
 0501                        .HasColumnType("integer");
 0502
 0503                    b.HasKey("Id");
 0504
 0505                    b.HasIndex("ActivityId")
 0506                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityId");
 0507
 0508                    b.HasIndex("ActivityInstanceId")
 0509                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityInstanceId");
 0510
 0511                    b.HasIndex("ActivityName")
 0512                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityName");
 0513
 0514                    b.HasIndex("ActivityType")
 0515                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityType");
 0516
 0517                    b.HasIndex("ActivityTypeVersion")
 0518                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityTypeVersion");
 0519
 0520                    b.HasIndex("EventName")
 0521                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_EventName");
 0522
 0523                    b.HasIndex("ParentActivityInstanceId")
 0524                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ParentActivityInstanceId");
 0525
 0526                    b.HasIndex("Sequence")
 0527                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_Sequence");
 0528
 0529                    b.HasIndex("TenantId")
 0530                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_TenantId");
 0531
 0532                    b.HasIndex("Timestamp")
 0533                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_Timestamp");
 0534
 0535                    b.HasIndex("WorkflowDefinitionId")
 0536                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_WorkflowDefinitionId");
 0537
 0538                    b.HasIndex("WorkflowDefinitionVersionId")
 0539                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_WorkflowDefinitionVersionId");
 0540
 0541                    b.HasIndex("WorkflowInstanceId")
 0542                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_WorkflowInstanceId");
 0543
 0544                    b.HasIndex("WorkflowVersion")
 0545                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_WorkflowVersion");
 0546
 0547                    b.HasIndex("ActivityType", "ActivityTypeVersion")
 0548                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_ActivityType_ActivityTypeVersion");
 0549
 0550                    b.HasIndex("Timestamp", "Sequence")
 0551                        .HasDatabaseName("IX_WorkflowExecutionLogRecord_Timestamp_Sequence");
 0552
 0553                    b.ToTable("WorkflowExecutionLogRecords", "Elsa");
 0554                });
 555
 0556            modelBuilder.Entity("Elsa.Workflows.Runtime.Entities.WorkflowInboxMessage", b =>
 0557                {
 0558                    b.Property<string>("Id")
 0559                        .HasColumnType("text");
 0560
 0561                    b.Property<string>("ActivityInstanceId")
 0562                        .HasColumnType("text");
 0563
 0564                    b.Property<string>("ActivityTypeName")
 0565                        .IsRequired()
 0566                        .HasColumnType("text");
 0567
 0568                    b.Property<string>("CorrelationId")
 0569                        .HasColumnType("text");
 0570
 0571                    b.Property<DateTimeOffset>("CreatedAt")
 0572                        .HasColumnType("timestamp with time zone");
 0573
 0574                    b.Property<DateTimeOffset>("ExpiresAt")
 0575                        .HasColumnType("timestamp with time zone");
 0576
 0577                    b.Property<string>("Hash")
 0578                        .IsRequired()
 0579                        .HasColumnType("text");
 0580
 0581                    b.Property<string>("SerializedBookmarkPayload")
 0582                        .HasColumnType("text");
 0583
 0584                    b.Property<string>("SerializedInput")
 0585                        .HasColumnType("text");
 0586
 0587                    b.Property<string>("TenantId")
 0588                        .HasColumnType("text");
 0589
 0590                    b.Property<string>("WorkflowInstanceId")
 0591                        .HasColumnType("text");
 0592
 0593                    b.HasKey("Id");
 0594
 0595                    b.HasIndex(new[] { "ActivityInstanceId" }, "IX_WorkflowInboxMessage_ActivityInstanceId");
 0596
 0597                    b.HasIndex(new[] { "ActivityTypeName" }, "IX_WorkflowInboxMessage_ActivityTypeName");
 0598
 0599                    b.HasIndex(new[] { "CorrelationId" }, "IX_WorkflowInboxMessage_CorrelationId");
 0600
 0601                    b.HasIndex(new[] { "CreatedAt" }, "IX_WorkflowInboxMessage_CreatedAt");
 0602
 0603                    b.HasIndex(new[] { "ExpiresAt" }, "IX_WorkflowInboxMessage_ExpiresAt");
 0604
 0605                    b.HasIndex(new[] { "Hash" }, "IX_WorkflowInboxMessage_Hash");
 0606
 0607                    b.HasIndex(new[] { "WorkflowInstanceId" }, "IX_WorkflowInboxMessage_WorkflowInstanceId");
 0608
 0609                    b.ToTable("WorkflowInboxMessages", "Elsa");
 0610                });
 611#pragma warning restore 612, 618
 0612        }
 613    }
 614}