BEST
DEALS
OF THE
YEAR!
SAVE UP TO $3,000
24 NOV
1 DEC
00 Days
00 Hrs
00 Min
00 Sec
Open Closed

Elsa Dashboard Integration error #1551


User avatar
0
viswajwalith created

ABP Framework version: v4.3 UI type: MVCDB provider: EF Core / MongoDB Tiered (MVC) or Identity Server Separated (Angular): yes , Microservice Architecture Exception message and stack trace:

Hi,

We are trying to integrate elsa dashboard, it worked perfectly in Application template, but when we try to integrate in microservice based ABP solution getting following error when accessing the elsa dashboard.


2 Answer(s)
  • User Avatar
    0
    liangshiwei created
    Fullstack Developer

    Hi,

    Can you provider steps to reproduce?

  • User Avatar
    0
    viswajwalith created

    Hi,

    Somwhow we are able to get that issue fixed by changing the way of configuring the elsa. Thanks for the support.

        private void ConfigureElsa(ServiceConfigurationContext context, IConfiguration configuration)
        {
            context.Services
                .AddElsa(
                    elsa =>
                    {
                        elsa
                        .AddMongoDbStores(configuration, databaseName: "AppV3_Elsa", connectionStringName: "ElsaServiceMongoDb");
    
                    })
    
                .AddEmailActivities(options => options.Bind(configuration.GetSection("Elsa:Smtp")))
                .AddHttpActivities(options => options.Bind(configuration.GetSection("Elsa:Server")))
                .AddTimerActivities(options => options.Bind(configuration.GetSection("Elsa:Timers")));
                
            context.Services.AddElsaDashboard(options => options.Configure(x => x.ActivityDefinitions
                                                    .Add<WriteLine>()
                                                    .Add<ReadLine>()
                                                    .Add<ReceiveHttpRequest>()
                                                    .Add<SendHttpRequest>()
                                                    .Add<WriteHttpResponse>()
                                                    .Add<SetVariable>()
                                                    .Add<ForEach>()
                                                ));
    
            context.Services.AddUserActivities();
            context.Services.AddAssemblyOf<Elsa.Dashboard.Areas.Elsa.Controllers.HomeController>();
            context.Services.AddAssemblyOf<Elsa.WorkflowDesigner.ViewComponents.WorkflowDesignerViewComponent>();
            context.Services.AddAssemblyOf<Elsa.Dashboard.Areas.Elsa.Controllers.WorkflowDefinitionController>();
            context.Services.AddAssemblyOf<Elsa.Dashboard.Areas.Elsa.Controllers.WorkflowInstanceController>();
    
            context.Services.AddNotificationHandlers(typeof(LiquidConfigurationHandler));
            //Disable antiforgery validation for elsa
            Configure<AbpAntiForgeryOptions>(options =>
            {
                options.AutoValidateFilter = type =>
                    type.Assembly != typeof(Elsa.Dashboard.Areas.Elsa.Controllers.HomeController).Assembly;
                options.AutoValidateFilter = type =>
                    type.Assembly != typeof(Elsa.WorkflowDesigner.ViewComponents.WorkflowDesignerViewComponent).Assembly;
                options.AutoValidateFilter = type =>
                    type.Assembly != typeof(Elsa.Dashboard.Areas.Elsa.Controllers.WorkflowDefinitionController).Assembly;
                options.AutoValidateFilter = type =>
                    type.Assembly != typeof(Elsa.Dashboard.Areas.Elsa.Controllers.WorkflowInstanceController).Assembly;
            });
    
        }
        
    
Boost Your Development
ABP Live Training
Packages
See Trainings
Mastering ABP Framework Book
The Official Guide
Mastering
ABP Framework
Learn More
Mastering ABP Framework Book
Made with ❤️ on ABP v10.1.0-preview. Updated on November 20, 2025, 09:12
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.