Update YesSql provider

This commit is contained in:
Sipke Schoorstra 2021-03-08 15:12:01 +01:00
parent d53aee02be
commit bbf04fb5c3
3 changed files with 5 additions and 9 deletions

View file

@ -18,7 +18,6 @@ namespace Elsa.Persistence.YesSql.Documents
public bool IsSingleton { get; set; }
public WorkflowPersistenceBehavior PersistenceBehavior { get; set; }
public bool DeleteCompletedInstances { get; set; }
public bool IsEnabled { get; set; }
public bool IsPublished { get; set; }
public bool IsLatest { get; set; }
public ICollection<ActivityDefinition> Activities { get; set; } = new List<ActivityDefinition>();

View file

@ -12,7 +12,6 @@ namespace Elsa.Persistence.YesSql.Indexes
public int Version { get; set; }
public bool IsLatest { get; set; }
public bool IsPublished { get; set; }
public bool IsEnabled { get; set; }
}
public class WorkflowDefinitionIndexProvider : IndexProvider<WorkflowDefinitionDocument>
@ -30,8 +29,7 @@ namespace Elsa.Persistence.YesSql.Indexes
DefinitionVersionId = workflowDefinition.DefinitionVersionId,
Version = workflowDefinition.Version,
IsPublished = workflowDefinition.IsPublished,
IsLatest = workflowDefinition.IsLatest,
IsEnabled = workflowDefinition.IsEnabled
IsLatest = workflowDefinition.IsLatest
}
);
}

View file

@ -16,8 +16,7 @@ namespace Elsa.Persistence.YesSql
.Column<string>(nameof(WorkflowDefinitionIndex.DefinitionVersionId))
.Column<int>(nameof(WorkflowDefinitionIndex.Version))
.Column<bool>(nameof(WorkflowDefinitionIndex.IsLatest))
.Column<bool>(nameof(WorkflowDefinitionIndex.IsPublished))
.Column<bool>(nameof(WorkflowDefinitionIndex.IsEnabled)),
.Column<bool>(nameof(WorkflowDefinitionIndex.IsPublished)),
CollectionNames.WorkflowDefinitions);
SchemaBuilder.CreateMapIndexTable<WorkflowInstanceIndex>(
@ -38,7 +37,7 @@ namespace Elsa.Persistence.YesSql
.Column(nameof(WorkflowInstanceIndex.FaultedAt), DbType.DateTime)
,
CollectionNames.WorkflowInstances);
SchemaBuilder.CreateMapIndexTable<WorkflowInstanceBlockingActivitiesIndex>(
table => table
.Column<string?>(nameof(WorkflowInstanceBlockingActivitiesIndex.TenantId))
@ -48,7 +47,7 @@ namespace Elsa.Persistence.YesSql
.Column(nameof(WorkflowInstanceBlockingActivitiesIndex.WorkflowStatus), DbType.String)
.Column(nameof(WorkflowInstanceBlockingActivitiesIndex.CreatedAt), DbType.DateTime),
CollectionNames.WorkflowInstances);
SchemaBuilder.CreateMapIndexTable<WorkflowExecutionLogRecordIndex>(
table => table
.Column<string?>(nameof(WorkflowExecutionLogRecordIndex.RecordId))
@ -56,7 +55,7 @@ namespace Elsa.Persistence.YesSql
.Column<string>(nameof(WorkflowExecutionLogRecordIndex.WorkflowInstanceId))
.Column(nameof(WorkflowExecutionLogRecordIndex.Timestamp), DbType.DateTime),
CollectionNames.WorkflowExecutionLog);
SchemaBuilder.CreateMapIndexTable<BookmarkIndex>(
table => table
.Column<string?>(nameof(BookmarkIndex.BookmarkId))