dotnet/orleans · critical · OrleansConfigurationException
No credentials specified. Use the {GetType().Name}.Configure
Error message
No credentials specified. Use the {GetType().Name}.ConfigureTableServiceClient method to configure the Azure Table Service client. What it means
Thrown by AzureStorageOperationOptions.Validate() when CreateClient is null — i.e. no credentials/client were ever configured for the Azure Table Service. Validate() runs during silo/client startup, so this surfaces as a blocking OrleansConfigurationException that prevents the host from booting. The message points you to the (now-obsolete) ConfigureTableServiceClient methods, but the recommended fix is to set TableServiceClient directly.
Source
Thrown at src/Azure/Shared/Storage/AzureStorageOperationOptions.cs:189
var delay = storagePolicyOptions.PauseBetweenOperationRetries > TimeSpan.Zero
? storagePolicyOptions.PauseBetweenOperationRetries
: TimeSpan.FromSeconds(0.8);
var maxDelay = storagePolicyOptions.MaxPauseBetweenOperationRetries == Timeout.InfiniteTimeSpan
? TimeSpan.FromMinutes(1)
: storagePolicyOptions.MaxPauseBetweenOperationRetries;
retryOptions.Mode = RetryMode.Exponential;
retryOptions.Delay = delay;
retryOptions.MaxDelay = maxDelay >= delay ? maxDelay : delay;
retryOptions.MaxRetries = Math.Max(0, storagePolicyOptions.MaxOperationRetries);
}
internal void Validate(string? name)
{
if (CreateClient is null)
{
throw new OrleansConfigurationException($"No credentials specified. Use the {GetType().Name}.{nameof(ConfigureTableServiceClient)} method to configure the Azure Table Service client.");
}
try
{
AzureTableUtils.ValidateTableName(TableName);
}
catch (Exception ex)
{
throw GetException($"{nameof(TableName)} is not valid.", ex);
}
Exception GetException(string message, Exception? inner = null) =>
new OrleansConfigurationException($"Configuration for {GetType().Name} {name} is invalid. {message}", inner!);
}
}
public class AzureStorageOperationOptionsValidator<TOptions> : IConfigurationValidator where TOptions : AzureStorageOperationOptions
{View on GitHub (pinned to fca799fa70)
Solutions
- Set options.TableServiceClient to a configured TableServiceClient instance (preferred), or call a ConfigureTableServiceClient overload.
- Ensure the assignment happens during startup configuration (e.g. in a PostConfigure or builder callback) before Validate runs.
- Confirm the right AzureStorageOperationOptions instance is the one being registered.
Example fix
// before
silo.AddAzureTableGrainStorage("Default", o => { o.TableName = "grainstate"; /* no client! */ });
// after
silo.AddAzureTableGrainStorage("Default", o =>
{
o.TableName = "grainstate";
o.TableServiceClient = new TableServiceClient(connectionString);
}); Defensive patterns
Strategy: validation
Validate before calling
void EnsureConfigured(AzureStorageOperationOptions o)
{
if (o.TableServiceClient is null && o.CreateClient is null)
throw new OrleansConfigurationException($"{nameof(AzureStorageOperationOptions)} has no TableServiceClient configured.");
} Type guard
static bool IsClientConfigured(AzureStorageOperationOptions o) => o.TableServiceClient is not null || o.CreateClient is not null;
Try / catch
catch (OrleansConfigurationException ex) when (ex.Message.Contains("No credentials specified")) { /* wire TableServiceClient before startup */ } Prevention
- Always assign TableServiceClient in the storage/clustering/reminders builder callback.
- Add a startup health check that validates each AzureStorageOperationOptions.
- After removing obsolete Configure calls, add the property assignment.
When it happens
Trigger: Registering an Azure Table-backed storage/clustering/reminders/streaming provider without ever calling any ConfigureTableServiceClient overload or assigning TableServiceClient. Also when a custom AzureStorageOperationOptions subclass leaves the client unassigned.
Common situations: Forgot to wire credentials for Azure Table storage; DI bound AzureStorageOperationOptions but no post-configuration set the client; migration where the Configure call was removed but the property assignment was not added.
Related errors
- No credentials specified. Use the {options.GetType().Name}.C
- Value cannot be null. (Parameter 'createClientCallback')
- Value cannot be null. (Parameter 'connectionString')
- Value cannot be null. (Parameter 'serviceUri')
- Value cannot be null. (Parameter 'tokenCredential')
AI-assisted analysis of dotnet/orleans@fca799fa70 (2026-08-13).
Data as JSON: /api/errors/8c68dc368981c989.
Report an issue: GitHub.