Open Closed

Deploy an single instance tiered modular monolith application to Azure App Services #10467


User avatar
0
chrisalves created
Environment Details

• ABP Framework Version: 9.2.1 • ABP Studio Version: 2.1.7 (Created with 0.9.25) • UI Framework: Blazor Server • Architecture: Tiered (Layered) • Database: SQL Server (EF Core) • Deployment: Azure App Service (Quality Environment) • Distributed Event Bus: RabbitMQ • Multi-Tenancy: Yes (Separate Tenant Schema) The application is built on ABP Framework version 9.2.1, originally created using ABP Studio version 0.9.25 and currently maintained under version 2.1.7. It utilizes a Tiered (Layered) architecture with a Blazor Server UI framework, authentication, api and webpublic servers. For data persistence, the system uses SQL Server managed via Entity Framework Core, featuring a Multi-Tenancy approach with Separate Tenant Schemas.

Description & Problem Statements

I am following the official ABP Deployment Documentation to deploy to Azure App Services, having each application “solution” its own Azure App Service. • AuthServer • HttpApiHost • BlazorServer • WebPublic

Issue 1: Azure Redis Cache Connection Failure

I am unable to establish a connection with Azure Redis Cache

  • Attempts made: I have configured the Redis Firewall to allow "all IP addresses" (0.0.0.0) for testing purposes, but the connection still fails.
  • Current Configuration: Previously, in local development, I used a simple IP address.
  • For Azure, I am attempting to use the full connection string provided by the Azure Portal

Question: Does the ABP Framework support passing the full Azure connection string directly into the standard Redis configuration field? Is there a specific format or property I should be using in the appsettings.json?

Issue 2: Disabling RabbitMQ for Single-Instance Deployment

The application is currently making constant connection attempts to RabbitMQ, leading to logs filled with connection errors. Since this is a Single-Instance deployment for a Quality environment, I do not require a distributed bus like RabbitMQ at this moment. • Requirements: I need a way to disable RabbitMQ or switch to a local/in-memory event bus following best practices. • Question 1: Is there any recommended configuration (via appsettings.json or modification of the HttpApiHostModule, AuthServerModule, and BlazorServerModule classes) to suppress RabbitMQ and use the internal memory bus? • Question 2: Is it expected behavior for the Blazor Server UI project to attempt direct connections to RabbitMQ in a tiered architecture?


Supporting Information

• References from articles taken into consideration: o https://abp.io/docs/9.2/deployment o https://abp.io/docs/9.2/get-started/pre-requirements


8 Answer(s)
  • User Avatar
    0
    AI-Bot created
    Support Team ABP Agent
    • Issue 1 (Azure Redis Cache): Yes, ABP supports passing the full Azure Redis connection string via Redis:Configuration.
      In ABP’s Azure deployment guidance for the layered (tiered) template, Redis is configured like this (note it’s the same “full string” format Azure provides, including password=..., ssl=true, etc.):

      appsettings.json (each app/service you deploy that uses distributed cache / data-protection):

    {
        "Redis": {
          "Configuration": "your-cache-name.redis.cache.windows.net:6380,password=YOUR_KEY,ssl=true,abortConnect=False"
        }
      }
    

    So you should use Redis:Configuration (not Redis:Host) and put the full Azure connection string value there.

    Important practical notes for Azure Cache for Redis:

    • Use port 6380 + ssl=true (Azure Redis typically requires TLS).

    • The “firewall allow all IPs” setting is not always the only gate; if you use Private Endpoint / VNET, the public endpoint won’t be reachable from App Service unless networking is configured accordingly. (This is Azure-side, not ABP-side.)

    • Issue 2 (Disable RabbitMQ / use in-memory bus): No verified source available in the provided context/tools for an ABP 9.2.1 “official/best-practice switch” to turn off RabbitMQ via only appsettings.json.
      What can be stated definitively:

      • If your solution references/configures the RabbitMQ distributed event bus, the processes that include that module/config will attempt to connect.
      • In a tiered setup, it can be expected that multiple apps (including the UI host like Blazor Server) may try to connect if they also include the RabbitMQ event bus module/configuration, because distributed events can be published/consumed from different tiers.

      Since I couldn’t verify the exact supported “disable RabbitMQ / fall back to in-memory” switch for ABP 9.2.1 from the available sources, I will not provide an unverified config/code change here.

    Sources (validated)

    • https://abp.io/docs/latest/solution-templates/layered-web-application/deployment/azure-deployment/step2-configuration-application
    • https://abp.io/docs/latest/framework/fundamentals/redis-cache
    • https://abp.io/community/articles/94old5rm

    This response was generated by AI. If it didn’t solve your problem, feel free to post a new answer — our support team will jump in to help you soon.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Does the ABP Framework support passing the full Azure connection string directly into the standard Redis configuration field? Is there a specific format or property I should be using in the appsettings.json?

    Yes. Abp will call the AddStackExchangeRedisCache to set up Redis

    context.Services.AddStackExchangeRedisCache(options =>
    {
        var redisConfiguration = configuration["Redis:Configuration"];
        options.Configuration = redisConfiguration;
    });
    

    See https://stackexchange.github.io/StackExchange.Redis/Configuration.html

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Issue 2: Disabling RabbitMQ for Single-Instance Deployment

    Your application is tiered, so you need a distributed event bus. However, if you need to disable it, you can replace AbpEventBusRabbitMqModule with AbpEventBusModule in your module dependencies.

    Thanks.

  • User Avatar
    0
    chrisalves created

    Issue 3: ABP Library Installation and Azure Deployment

    Context: The application is being published directly from Microsoft Visual Studio to an Azure App Service. The goal is to ensure that all necessary ABP libraries and client-side dependencies are correctly included in the remote server.

    Core Question: What is the proper procedure to ensure all required libraries are bundled and sent to the remote server during the Visual Studio publish process?

    References: https://abp.io/docs/9.2/get-started/pre-requirements

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    You can run the abp install-libs command before publishing, or add this command to your publish pipeline.

    Thanks.

  • User Avatar
    0
    chrisalves created

    [maliming] said: hi

    Issue 2: Disabling RabbitMQ for Single-Instance Deployment

    Your application is tiered, so you need a distributed event bus. However, if you need to disable it, you can replace AbpEventBusRabbitMqModule with AbpEventBusModule in your module dependencies.

    Thanks.

    Hi Support Team,

    Following up on the second issue (EventBus configuration).

    Per your recommendation, we are temporarily switching from RabbitMQ to the default ABP EventBus (in-process) to move forward. However, our plan is to adopt the recommended best-practice setup in the near future, likely using RabbitMQ as the distributed event bus.

    The attached image shows the current appsettings.json from our Blazor Server WebApp, which still includes RabbitMQ-related settings (for example, RabbitMQ:Connections:Default:HostName = "localhost").

    Questions (short term – ABP EventBus)

    1. After switching to the default ABP EventBus, what exactly should we remove or change in the configuration files (appsettings.json and environment-specific settings) for:

      • Blazor Server WebApp
      • API/HttpApi.Host
      • AuthServer (if applicable)
    2. With the default ABP EventBus, does any server/service (AuthServer vs API) need to host the event bus, or is it purely in-process per application (meaning no endpoint/host configuration is required)?

    Questions (near future – RabbitMQ best practice)

    1. When we move back to RabbitMQ, we’ll need to run it as an external/shared infrastructure component. Since our infrastructure is hosted on Azure, we would prefer an Azure-friendly option.
      • What hosting approach or managed service do you recommend for RabbitMQ in production (Azure-first if possible)?
      • If Azure isn’t ideal for managed RabbitMQ, are there external providers/services you commonly recommend based on your experience (ease of setup, reliability, maintenance)?

    Thanks in advance for confirming the correct configuration changes now, and for advising on the best RabbitMQ hosting option for our upcoming production-ready setup.

  • User Avatar
    0
    chrisalves created

    [maliming] said: hi

    You can run the abp install-libs command before publishing, or add this command to your publish pipeline.

    Thanks.

    Following up on the Libs issue, the screenshot below shows the related error:

    The application works correctly in my Development environment because the abp install-libs command was executed when the solution was created.

    For troubleshooting, I checked the published Blazor Server application on Azure App Service, and the wwwroot/libs folder does exist in the deployed files, as shown below:

    Given that the folder is present after publishing, could you please advise what else might cause ABP to report that the Libs folder is missing in this environment (e.g., path resolution, static file configuration, deployment slot/file sync, or any ABP setting that affects the libs check)?

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    1. Can you restart the app to test again after installing the libraries?
    2. What is the value of your webHostEnvironment.WebRootPath? You can see it in your app startup debug logs.
    3. You can also try to disable it and test again
    Configure<AbpMvcLibsOptions>(options =>
    {
        options.CheckLibs = false;
    });
    

    Thanks.

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.3.0-preview. Updated on February 27, 2026, 05:41
1
ABP Assistant
🔐 You need to be logged in to use the chatbot. Please log in first.