abpframework/abp · error · AbpException
No BLOB Storage provider was used! At least one provider mus
Error message
No BLOB Storage provider was used! At least one provider must be configured to be able to use the BLOB Storing System.
What it means
Thrown when at least one IBlobProvider is registered, but the specific container being resolved has no ProviderType configured (configuration.ProviderType == null). ProviderType is set by the Use* extension methods (UseFileSystemStorage, UseAzureBlobStorage, etc.); a null value means the container was declared without a backing provider, or a default provider was never set.
Source
Thrown at framework/src/Volo.Abp.BlobStoring/Volo/Abp/BlobStoring/DefaultBlobProviderSelector.cs:38
ConfigurationProvider = configurationProvider;
BlobProviders = blobProviders;
}
[NotNull]
public virtual IBlobProvider Get([NotNull] string containerName)
{
Check.NotNull(containerName, nameof(containerName));
var configuration = ConfigurationProvider.Get(containerName);
if (!BlobProviders.Any())
{
throw new AbpException("No BLOB Storage provider was registered! At least one provider must be registered to be able to use the BLOB Storing System.");
}
if (configuration.ProviderType == null)
{
throw new AbpException("No BLOB Storage provider was used! At least one provider must be configured to be able to use the BLOB Storing System.");
}
foreach (var provider in BlobProviders)
{
if (ProxyHelper.GetUnProxiedType(provider).IsAssignableTo(configuration.ProviderType))
{
return provider;
}
}
throw new AbpException(
$"Could not find the BLOB Storage provider with the type ({configuration.ProviderType.AssemblyQualifiedName}) configured for the container {containerName} and no default provider was set."
);
}
}
View on GitHub (pinned to 7ed43b1931)
Solutions
- Configure the container's provider via Configure<AbpBlobStoringOptions>(o => o.Containers.Configure<MyContainer>(c => c.UseFileSystemStorage())) or the typed extension.
- Set a default provider for all containers with o.Containers.ConfigureDefault(c => c.Use<ProviderType>()).
- Confirm the container name attribute matches the configuration key you are configuring.
- Ensure the Use* extension for your chosen provider is actually invoked at module configuration time.
Example fix
// before: container used without a provider type
Configure<AbpBlobStoringOptions>(options =>
{
options.Containers.Configure<MyFileContainer>(c => { /* no Use* call */ });
});
// after: specify the provider for the container
Configure<AbpBlobStoringOptions>(options =>
{
options.Containers.Configure<MyFileContainer>(c => c.UseFileSystemStorage());
}); Defensive patterns
Strategy: validation
Validate before calling
// Confirm the container has a ProviderType configured before first use.
var config = configurationProvider.Get(containerName);
if (config.ProviderType == null)
{
throw new InvalidOperationException($"Container '{containerName}' has no ProviderType. Call a Use* extension (e.g., UseFileSystemStorage) or configure a default provider.");
} Type guard
public static bool ContainerHasProviderType(BlobContainerConfiguration config) =>
config.ProviderType is not null; Try / catch
try
{
provider = selector.Get(containerName);
}
catch (AbpException ex) when (ex.Message.Contains("No BLOB Storage provider was used", StringComparison.Ordinal))
{
logger.LogError(ex, "Container {Name} lacks a provider configuration.", containerName);
throw;
} Prevention
- Always pair a container declaration with its Use<Provider> configuration call.
- Set a default provider via ConfigureDefault to cover unconfigured containers.
- Validate container configurations in a module post-configure hook.
- Use the same container name in the attribute and the configuration to avoid silent unconfigured lookups.
When it happens
Trigger: DefaultBlobProviderSelector.Get(containerName) runs after BlobProviders is non-empty, but ConfigurationProvider.Get(containerName).ProviderType is null. Happens when a container is used without configuring it, and no default ProviderType is configured for all containers.
Common situations: Using IBlobContainer<T> without calling the Use<Provider> extension on its configuration; defining a default container configuration that omits the provider; typo in container name causing it to resolve an unconfigured default; mixing configured and unconfigured containers.
Related errors
- Could not find the BLOB Storage provider with the type ({con
- The BLOB was encrypted with a tenant-specific passphrase, bu
- The BLOB was encrypted with the '{keySource}' passphrase, bu
- No BLOB Storage provider was registered! At least one provid
- code length overflow. (${buffer.getLengthInBits()}>${totalDa
AI-assisted analysis of abpframework/abp@7ed43b1931 (2026-08-13).
Data as JSON: /api/errors/a0675b2ac8251f3a.
Report an issue: GitHub.