Cleanup namespaces

This commit is contained in:
Sipke Schoorstra 2023-07-09 14:02:41 +02:00
parent fe2a897a30
commit 9671d85013
169 changed files with 63 additions and 203 deletions

View file

@ -1,4 +1,3 @@
using Elsa.Api.Client.Resources.ActivityDescriptors.Models;
using Elsa.Api.Client.Resources.ActivityDescriptors.Requests;
using Elsa.Api.Client.Resources.ActivityDescriptors.Responses;
using Refit;

View file

@ -1,4 +1,3 @@
using Elsa.Api.Client.Resources.StorageDrivers.Models;
using Elsa.Api.Client.Resources.StorageDrivers.Responses;
using Refit;

View file

@ -1,4 +1,3 @@
using Elsa.Api.Client.Resources.VariableTypes.Models;
using Elsa.Api.Client.Resources.VariableTypes.Responses;
using Refit;

View file

@ -8,7 +8,6 @@ using Elsa.Dapper.Services;
using Elsa.Extensions;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Entities;
using Elsa.Workflows.Management.Filters;

View file

@ -4,7 +4,6 @@ using Elsa.Dapper.Modules.Runtime.Records;
using Elsa.Dapper.Services;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Runtime.Contracts;

View file

@ -1,4 +1,4 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
namespace Elsa.Dsl.Contracts;

View file

@ -1,6 +1,5 @@
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Dsl.Interpreters;

View file

@ -1,8 +1,8 @@
using Antlr4.Runtime;
using Elsa.Dsl.Contracts;
using Elsa.Dsl.Interpreters;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Dsl.Services;

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,5 +1,4 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable

View file

@ -1,6 +1,5 @@
using System.Linq.Expressions;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Management.Entities;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Runtime.Entities;
using Microsoft.EntityFrameworkCore;

View file

@ -2,7 +2,6 @@ using Elsa.Common.Contracts;
using Elsa.EntityFrameworkCore.Common;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Runtime.Contracts;
using Microsoft.EntityFrameworkCore;

View file

@ -3,7 +3,6 @@ using Elsa.Http.Models;
using Elsa.Http.Options;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Helpers;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Runtime.Contracts;
using JetBrains.Annotations;
using Microsoft.AspNetCore.Http;

View file

@ -5,7 +5,6 @@ using Elsa.JavaScript.Notifications;
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using Humanizer;
using JetBrains.Annotations;
using Jint;

View file

@ -9,7 +9,6 @@ using Elsa.JavaScript.Notifications;
using Elsa.JavaScript.Options;
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using Humanizer;
using Jint;
using Microsoft.Extensions.Options;

View file

@ -1,4 +1,4 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
namespace Elsa.JavaScript.TypeDefinitions.Models;

View file

@ -6,7 +6,6 @@ using Elsa.Liquid.Notifications;
using Elsa.Liquid.Options;
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Management.Options;
using Fluid;
using Fluid.Values;

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
namespace Elsa.Liquid.Helpers;

View file

@ -4,7 +4,6 @@ using Elsa.Expressions.Models;
using Elsa.Extensions;
using Elsa.MassTransit.Implementations;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
namespace Elsa.MassTransit.Activities;

View file

@ -3,7 +3,6 @@ using Elsa.Features.Services;
using Elsa.MongoDB.Options;
using Elsa.MongoDb.Serializers;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Options;
using MongoDB.Bson.Serialization;

View file

@ -1,9 +1,7 @@
using Elsa.Common.Models;
using Elsa.Extensions;
using Elsa.MongoDb.Common;
using Elsa.MongoDb.Extensions;
using Elsa.MongoDb.Helpers;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Entities;
using Elsa.Workflows.Management.Filters;

View file

@ -1,6 +1,4 @@
using Elsa.MongoDb.Common;
using Elsa.MongoDb.Extensions;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Runtime.Contracts;
using Elsa.Workflows.Runtime.Entities;
using MongoDB.Driver.Linq;

View file

@ -2,7 +2,6 @@ using Elsa.Features.Attributes;
using Elsa.Features.Services;
using Elsa.MongoDb.Common;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Runtime.Entities;
using Elsa.Workflows.Runtime.Features;
using Microsoft.Extensions.DependencyInjection;

View file

@ -1,5 +1,4 @@
using Elsa.MongoDb.Common;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Runtime.Contracts;
using Elsa.Workflows.Runtime.Entities;
using MongoDB.Driver.Linq;

View file

@ -1,8 +1,6 @@
using Elsa.Common.Contracts;
using Elsa.MongoDb.Common;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Runtime.Contracts;
using MongoDB.Driver;

View file

@ -1,6 +1,5 @@
using Elsa.WorkflowContexts.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.WorkflowContexts.Abstractions;

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
namespace Elsa.WorkflowContexts.Contracts;

View file

@ -1,7 +1,6 @@
using Elsa.Expressions.Models;
using Elsa.WorkflowContexts.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
// ReSharper disable once CheckNamespace

View file

@ -1,5 +1,5 @@
using Elsa.WorkflowContexts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -2,7 +2,6 @@ using Elsa.Extensions;
using Elsa.WorkflowContexts.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.ActivityExecution;
using Elsa.Workflows.Runtime.Middleware.Activities;
using Microsoft.Extensions.DependencyInjection;

View file

@ -1,7 +1,6 @@
using Elsa.Extensions;
using Elsa.WorkflowContexts.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.WorkflowExecution;
using Microsoft.Extensions.DependencyInjection;

View file

@ -7,7 +7,7 @@ using Elsa.JavaScript.TypeDefinitions.Contracts;
using Elsa.JavaScript.TypeDefinitions.Models;
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
namespace Elsa.WorkflowContexts.Scripting.JavaScript;

View file

@ -3,7 +3,7 @@ using Elsa.Abstractions;
using Elsa.Common.Models;
using Elsa.JavaScript.TypeDefinitions.Contracts;
using Elsa.JavaScript.TypeDefinitions.Models;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Management.Contracts;
using JetBrains.Annotations;

View file

@ -1,13 +1,6 @@
using Elsa.Abstractions;
using Elsa.Common.Entities;
using Elsa.Common.Models;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Serialization.Converters;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Filters;
using Elsa.Workflows.Management.Mappers;
using JetBrains.Annotations;
using Microsoft.AspNetCore.Http;
namespace Elsa.Workflows.Api.Endpoints.WorkflowDefinitions.Count;

View file

@ -4,7 +4,6 @@ using Elsa.Common.Models;
using Elsa.Http.Contracts;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Filters;

View file

@ -1,6 +1,4 @@
using Elsa.Abstractions;
using Elsa.Common.Entities;
using Elsa.Common.Models;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Serialization.Converters;
using Elsa.Workflows.Management.Contracts;

View file

@ -1,13 +1,6 @@
using Elsa.Abstractions;
using Elsa.Common.Entities;
using Elsa.Common.Models;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Serialization.Converters;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Filters;
using Elsa.Workflows.Management.Mappers;
using JetBrains.Annotations;
using Microsoft.AspNetCore.Http;
namespace Elsa.Workflows.Api.Endpoints.WorkflowDefinitions.IsNameUnique;

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
namespace Elsa.Workflows.Api.Endpoints.WorkflowInstances.Get;

View file

@ -3,7 +3,6 @@ using Elsa.Common.Entities;
using Elsa.Common.Models;
using Elsa.Workflows.Api.Models;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Management.Contracts;
using Elsa.Workflows.Management.Filters;
using Elsa.Workflows.Management.Models;

View file

@ -1,7 +1,6 @@
using Elsa.Common.Entities;
using Elsa.Workflows.Api.Models;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Management.Models;
namespace Elsa.Workflows.Api.Endpoints.WorkflowInstances.List;

View file

@ -1,5 +1,4 @@
using System.Text.Json;
using Elsa.Workflows.Api.Endpoints.WorkflowInstances.List;
using Elsa.Workflows.Core.Contracts;
using Microsoft.Extensions.DependencyInjection;

View file

@ -1,6 +1,5 @@
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Abstractions;

View file

@ -2,7 +2,6 @@ using System.Runtime.CompilerServices;
using System.Text.Json.Serialization;
using Elsa.Extensions;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Signals;
using JetBrains.Annotations;

View file

@ -2,7 +2,6 @@ using System.Collections.ObjectModel;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Activities;

View file

@ -1,7 +1,6 @@
using System.Runtime.CompilerServices;
using System.Text.Json.Serialization;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -3,7 +3,6 @@ using System.Text.Json.Serialization;
using Elsa.Extensions;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities.Flowchart.Activities;

View file

@ -7,7 +7,6 @@ using Elsa.Workflows.Core.Activities.Flowchart.Extensions;
using Elsa.Workflows.Core.Activities.Flowchart.Models;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Signals;
using JetBrains.Annotations;

View file

@ -5,7 +5,6 @@ using System.Text.Json.Serialization;
using Elsa.Extensions;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -3,7 +3,6 @@ using System.Runtime.CompilerServices;
using System.Text.Json.Serialization;
using Elsa.Expressions.Models;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -1,6 +1,5 @@
using System.ComponentModel;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -4,7 +4,6 @@ using System.Text.Json.Serialization;
using Elsa.Extensions;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -4,7 +4,6 @@ using System.Text.Json.Serialization;
using Elsa.Extensions;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Signals;
using JetBrains.Annotations;

View file

@ -1,7 +1,6 @@
using System.Runtime.CompilerServices;
using System.Text.Json.Serialization;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Activities;

View file

@ -1,12 +1,12 @@
using System.ComponentModel;
using Elsa.Expressions.Models;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Attributes;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using JetBrains.Annotations;
namespace Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Activities;
/// <summary>
/// Represents an executable process.

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Attributes;
[AttributeUsage(AttributeTargets.Class)]

View file

@ -1,6 +1,5 @@
using Elsa.Extensions;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Behaviors;

View file

@ -1,6 +1,5 @@
using Elsa.Extensions;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Signals;
namespace Elsa.Workflows.Core.Behaviors;

View file

@ -1,6 +1,5 @@
using Elsa.Extensions;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Signals;
namespace Elsa.Workflows.Core.Behaviors;

View file

@ -1,6 +1,6 @@
using Elsa.Expressions.Models;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core;

View file

@ -1,5 +1,4 @@
using System.Text.Json.Serialization;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
public interface IActivityExecutionMiddleware

View file

@ -1,4 +1,3 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.ActivityExecution;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
public interface IActivityInvoker

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
public interface IBehavior : ISignalHandler

View file

@ -1,6 +1,5 @@
using Elsa.Expressions.Models;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,3 +1,4 @@
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
public interface ISignalHandler

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
/// <summary>

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
/// <summary>

View file

@ -1,4 +1,4 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,3 +1,4 @@
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;

View file

@ -1,4 +1,4 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Services;
using Elsa.Workflows.Core.State;

View file

@ -1,4 +1,3 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,5 +1,3 @@
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Contracts;
public interface IWorkflowExecutionMiddleware

View file

@ -1,4 +1,3 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.WorkflowExecution;
namespace Elsa.Workflows.Core.Contracts;

View file

@ -1,4 +1,5 @@
using Elsa.Workflows.Core.Abstractions;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.State;

View file

@ -1,7 +1,6 @@
using Elsa.Expressions.Contracts;
using Elsa.Expressions.Models;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Expressions;

View file

@ -1,6 +1,7 @@
using Elsa.Expressions.Helpers;
using Elsa.Expressions.Models;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;

View file

@ -1,7 +1,6 @@
using Elsa.Expressions.Helpers;
using Elsa.Expressions.Models;
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Models;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -1,7 +1,6 @@
using Elsa.Workflows.Core;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Helpers;
using Elsa.Workflows.Core.Models;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -1,5 +1,4 @@
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -2,7 +2,6 @@ using System.Text.Json;
using Elsa.Expressions.Helpers;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Memory;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Serialization.Converters;
using Elsa.Workflows.Core.Services;

View file

@ -1,5 +1,5 @@
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -1,4 +1,4 @@
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
// ReSharper disable once CheckNamespace
namespace Elsa.Extensions;

View file

@ -1,6 +1,5 @@
using System.Diagnostics;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.ActivityExecution;
using Microsoft.Extensions.Logging;

View file

@ -1,6 +1,5 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Notifications;
using Elsa.Workflows.Core.Pipelines.ActivityExecution;

View file

@ -1,28 +1,27 @@
using Elsa.Extensions;
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Pipelines.WorkflowExecution;
namespace Elsa.Workflows.Core.Middleware.Workflows;
/// <summary>
/// Installs middleware that executes scheduled activities.
/// Installs middleware that executes scheduled work items.
/// </summary>
public static class UseActivitySchedulerMiddlewareExtensions
{
/// <summary>
/// Installs middleware that executes scheduled activities.
/// Installs middleware that executes scheduled work items.
/// </summary>
public static IWorkflowExecutionPipelineBuilder UseDefaultActivityScheduler(this IWorkflowExecutionPipelineBuilder pipelineBuilder) => pipelineBuilder.UseMiddleware<DefaultActivitySchedulerMiddleware>();
public static IWorkflowExecutionPipelineBuilder UseDefaultActivityScheduler(this IWorkflowExecutionPipelineBuilder pipelineBuilder) => pipelineBuilder.UseMiddleware<DefaultWorkSchedulerMiddleware>();
}
/// <summary>
/// A workflow execution middleware component that executes scheduled activities.
/// A workflow execution middleware component that executes scheduled work items.
/// </summary>
public class DefaultActivitySchedulerMiddleware : WorkflowExecutionMiddleware
public class DefaultWorkSchedulerMiddleware : WorkflowExecutionMiddleware
{
/// <inheritdoc />
public DefaultActivitySchedulerMiddleware(WorkflowMiddlewareDelegate next) : base(next)
public DefaultWorkSchedulerMiddleware(WorkflowMiddlewareDelegate next) : base(next)
{
}
@ -30,11 +29,11 @@ public class DefaultActivitySchedulerMiddleware : WorkflowExecutionMiddleware
public override async ValueTask InvokeAsync(WorkflowExecutionContext context)
{
var scheduler = context.Scheduler;
// Transition into the Executing state.
context.TransitionTo(WorkflowSubStatus.Executing);
// As long as there are activities scheduled, keep executing them.
// As long as there are work items scheduled, keep executing them.
while (scheduler.HasAny)
{
// Pop next work item for execution.
@ -46,9 +45,9 @@ public class DefaultActivitySchedulerMiddleware : WorkflowExecutionMiddleware
// Invoke next middleware.
await Next(context);
// If all activities are completed, complete the workflow.
if (context.Status == WorkflowStatus.Running)
if (context.Status == WorkflowStatus.Running)
context.TransitionTo(context.AllActivitiesCompleted() ? WorkflowSubStatus.Finished : WorkflowSubStatus.Suspended);
}
}

View file

@ -1,3 +1,4 @@
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.State;
namespace Elsa.Workflows.Core.Models;

View file

@ -1,5 +1,4 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Notifications;

View file

@ -1,5 +1,4 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Notifications;

View file

@ -1,5 +1,4 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Notifications;

View file

@ -1,5 +1,5 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
using Elsa.Workflows.Core.State;
namespace Elsa.Workflows.Core.Notifications;

View file

@ -1,5 +1,5 @@
using Elsa.Mediator.Contracts;
using Elsa.Workflows.Core.Models;
using Elsa.Workflows.Core.Activities;
namespace Elsa.Workflows.Core.Notifications;

View file

@ -1,6 +1,5 @@
using Elsa.Workflows.Core.Contracts;
using Elsa.Workflows.Core.Middleware.Activities;
using Elsa.Workflows.Core.Models;
namespace Elsa.Workflows.Core.Pipelines.ActivityExecution;

Some files were not shown because too many files have changed in this diff Show more