Open Closed

Could not find BLOB Storage provider with the type [...].DatabaseBlobProvider #9824


User avatar
0
MichelZ created
  • Template: app
  • Created ABP Studio Version: 0.9.12
  • Current ABP Studio Version: 1.2.2
  • Tiered: Yes
  • Multi-Tenancy: Yes
  • UI Framework: angular
  • Theme: leptonx
  • Theme Style: system
  • Progressive Web App: No
  • Database Provider: ef
  • Database Management System: postgresql
  • Separate Tenant Schema: Yes
  • Mobile Framework: none
  • Public Website: Yes
  • Include Tests: Yes
  • Optional Modules:
    • GDPR
    • FileManagement
    • TextTemplateManagement
    • LanguageManagement
    • AuditLogging
    • SaaS
    • OpenIddictAdmin

ABP Version 9.3.1

2025-08-28T11:44:30|ERROR|P:163720|T:20|AbpExceptionFilter||An exception was thrown while activating Volo.Saas.Host.TenantController -> company.product.Tenants.productTenantAppService -> Volo.Abp.Account.AccountAppService -> Volo.Abp.BlobStoring.BlobContainer`1[[Volo.Abp.Account.AccountProfilePictureContainer, Volo.Abp.Account.Pro.Public.Application, Version=9.3.1.0, Culture=neutral, PublicKeyToken=null]].
EXCEPTION: Autofac.Core.DependencyResolutionException: An exception was thrown while activating Volo.Saas.Host.TenantController -> company.product.Tenants.productTenantAppService -> Volo.Abp.Account.AccountAppService -> Volo.Abp.BlobStoring.BlobContainer`1[[Volo.Abp.Account.AccountProfilePictureContainer, Volo.Abp.Account.Pro.Public.Application, Version=9.3.1.0, Culture=neutral, PublicKeyToken=null]].
 ---> Autofac.Core.DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(Volo.Abp.BlobStoring.IBlobContainerFactory)' on type 'BlobContainer`1'.
 ---> Volo.Abp.AbpException: Could not find the BLOB Storage provider with the type (Volo.Abp.BlobStoring.Database.DatabaseBlobProvider, Volo.Abp.BlobStoring.Database.Domain, Version=9.3.1.0, Culture=neutral, PublicKeyToken=null) configured for the container account-profile-pictures and no default provider was set.
   at Volo.Abp.BlobStoring.DefaultBlobProviderSelector.Get(String containerName)
   at Volo.Abp.BlobStoring.BlobContainerFactory.Create(String name)
   at lambda_method3887(Closure, Object[])
   at Autofac.Core.Activators.Reflection.BoundConstructor.Instantiate()
   --- End of inner exception stack trace ---
   at Autofac.Core.Activators.Reflection.BoundConstructor.Instantiate()
   at Autofac.Core.Activators.Reflection.ReflectionActivator.<>c__DisplayClass14_0.<UseSingleConstructorActivation>b__0(ResolveRequestContext context, Action`1 next)
   at Autofac.Core.Resolving.Middleware.DisposalTrackingMiddleware.Execute(ResolveRequestContext context, Action`1 next)
   at Autofac.Builder.RegistrationBuilder`3.<>c__DisplayClass41_0.<PropertiesAutowired>b__0(ResolveRequestContext context, Action`1 next)
   at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action`1 next)
   --- End of inner exception stack trace ---
   at Autofac.Core.Resolving.Middleware.ActivatorErrorHandlingMiddleware.Execute(ResolveRequestContext context, Action`1 next)
   at Autofac.Core.Resolving.Middleware.SharingMiddleware.Execute(ResolveRequestContext context, Action`1 next)
   at Autofac.Core.Resolving.Middleware.CircularDependencyDetectorMiddleware.Execute(ResolveRequestContext context, Action`1 next)
   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, ResolveRequest& request)
   at Autofac.Core.Resolving.ResolveOperation.ExecuteOperation(ResolveRequest& request)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
   at Microsoft.AspNetCore.Mvc.Controllers.ControllerFactoryProvider.&lt;&gt;c__DisplayClass6_0.&lt;CreateControllerFactory&gt;g__CreateController|0(ControllerContext controllerContext)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.Next(State& next, Scope& scope, Object& state, Boolean& isCompleted)
   at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.InvokeInnerFilterAsync()
--- End of stack trace from previous location ---
   at Microsoft.AspNetCore.Mvc.Infrastructure.ResourceInvoker.&lt;InvokeNextExceptionFilterAsync&gt;g__Awaited|26_0(ResourceInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)

We have added the Minio BLOB provider to create new containers. We have added this to the ConfigureServices of the productHttpApiHostModule.cs:

Configure&lt;AbpBlobStoringOptions&gt;(options =>
 {
     options.Containers.ConfigureDefault(container =>
     {
         container.UseDatabase();
     });

     options.Containers.Configure&lt;AIModelBlobContainer&gt;(container =>
     {
         container.IsMultiTenant = false;

         container.UseMinio(minio =>
         {
             // Manual configuration binding - ABP's automatic binding is failing
             var configuration = context.Services.GetConfiguration();
             var blobSection = configuration.GetSection("BlobStoring:Containers:AIModelBlobContainer:Minio");

             minio.EndPoint = blobSection["EndPoint"];
             minio.AccessKey = blobSection["AccessKey"];
             minio.SecretKey = blobSection["SecretKey"];
             minio.BucketName = blobSection["BucketName"];
             minio.WithSSL = bool.Parse(blobSection["WithSSL"] ?? "true");
         });
     });
 });

7 Answer(s)
  • User Avatar
    0
    AI-Bot created
    Support Team ABP Agent

    To resolve the error "Could not find the BLOB Storage provider with the type (Volo.Abp.BlobStoring.Database.DatabaseBlobProvider...)", you must ensure that:

    1. The Database BLOB provider NuGet package is installed in your project:
    dotnet add package Volo.Abp.BlobStoring.Database
    
    1. The module dependency is declared in your module class (e.g., in your *.HttpApi.Host or main module):
    [DependsOn(typeof(AbpBlobStoringDatabaseModule))]
       public class YourModule : AbpModule
       {
           // ...
       }
    
    1. The provider is configured in ConfigureServices:
    Configure<AbpBlobStoringOptions>(options =>
       {
           options.Containers.ConfigureDefault(container =>
           {
               container.UseDatabase();
           });
           // Your other container configurations...
       });
    
    1. If you are using the File Management or Account module (which uses AccountProfilePictureContainer), ensure the default provider is set or that you configure the specific container:
    options.Containers.Configure<AccountProfilePictureContainer>(container =>
       {
           container.UseDatabase();
       });
    
    1. If you have multiple providers (e.g., Minio and Database), you must configure each container explicitly to use the correct provider. The default provider is only used for containers that are not explicitly configured.

    2. Restart your application after making these changes.

    This will register the Database BLOB provider and resolve the exception.

    Sources:


    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

    Can you share the steps or project that I can reproduce this exception?

    liming.ma@volosoft.com

    Thanks.

  • User Avatar
    0
    MichelZ created

    [maliming] said: hi

    Can you share the steps or project that I can reproduce this exception?

    liming.ma@volosoft.com

    Thanks.

    The steps are to add minio as a BLOB provider and configure it for a container. Can't share the project unfortunately as it's our entire product

  • User Avatar
    0
    MichelZ created

    Oh, and the exception happens when we e.g. go to the Tenant list in the Host, or to Audit logs

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Can you add your test code to a new template project and share it?

    Thanks.

  • User Avatar
    0
    MichelZ created

    Thanks. After tinkering a few more with it I found the issue... I wanted to replace the MinioBlobProvider with our own, but we had replaced IBlobProvider instead of the MinioBlobProvider 🤦 After fixing that, it works again now. Thx :)

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    😉

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.0.0-preview. Updated on September 01, 2025, 08:37