Watch Aspire live streamsDocsTry Aspire

RadiusBackingResourceProjectionException

Classsealednet10.0
📦 Aspire.Hosting.Radius v13.6.0-preview.1.26478.8
Thrown when a Radius backing resource — a cache, database, or queue provisioned by a Radius recipe rather than deployed as a Radius.Compute/containers workload — cannot be projected to its consumers: its address cannot be determined, or the recipe's own connection and credential outputs cannot be described.
namespace Aspire.Hosting.Radius;
public sealed class RadiusBackingResourceProjectionException
: System.InvalidOperationException
{
// ...
}
InvalidOperationException

A backing resource's Kubernetes objects and credentials are created by its recipe, so no value derived from the Aspire endpoint model describes it. The Radius publisher projects the address out of the recipe's own outputs instead. Every other route to that address — including RadiusEnvironmentResource.GetHostAddressExpression and the cross-environment endpoint resolution other compute publishers use — would have to guess, so it throws this exception rather than emitting an address that silently resolves to nothing. See https://github.com/microsoft/aspire/issues/18935.

This type is public because it can surface from a Kubernetes, Azure Container Apps, or Azure App Service publish: those publishers resolve a cross-environment reference through the Radius environment that owns the resource. Catching it requires a type an AppHost author can name.

It derives from InvalidOperationException to match the package's publish-time failure convention. Note that AzureAppServiceEnvironmentResource 's validation pass catches InvalidOperationException around its context lookup; that catch does not cover environment-variable resolution, so this exception is not swallowed there.

View all constructors
View all properties

Deploying the consumer and the backing resource to the same Radius environment resolves the address case. An AppHost that publishes several environments can report the offending resource:

try
{
await app.RunAsync();
}
catch (RadiusBackingResourceProjectionException ex)
{
Console.Error.WriteLine($"'{ex.Resource.Name}' is provisioned by a Radius recipe and cannot " +
$"be projected to its consumers: {ex.Message}");
}