using Elsa.Features.Abstractions;
using Elsa.Features.Attributes;
using Elsa.Features.Services;
using Elsa.MassTransit.Implementations;
using Elsa.Workflows.Runtime.Features;
using Elsa.Workflows.Runtime.Services;
using Microsoft.Extensions.DependencyInjection;
namespace Elsa.MassTransit.Features;
///
/// Configures the system to use a MassTransit implementation of ;
///
[DependsOn(typeof(WorkflowRuntimeFeature))]
public class MassTransitWorkflowDispatcherFeature : FeatureBase
{
///
public MassTransitWorkflowDispatcherFeature(IModule module) : base(module)
{
}
///
public override void Configure()
{
Module.Configure(f => f.WorkflowDispatcher = ActivatorUtilities.GetServiceOrCreateInstance);
}
}