65 instantiations of EndpointReference
Aspire.Hosting (8)
ApplicationModel\ResourceExtensions.cs (6)
704return endpoints.Select(e => new EndpointReference(resource, e)); 720return endpoints.Select(e => new EndpointReference(resource, e, contextNetworkID)); 739return new EndpointReference(resource, endpointName); 743return new EndpointReference(resource, endpoint); 762return new EndpointReference(resource, endpointName, contextNetworkID); 766return new EndpointReference(resource, endpoint, contextNetworkID);
Orchestrator\ApplicationOrchestrator.cs (1)
236var endpointReference = new EndpointReference(resourceWithEndpoints, endpoint, endpoint.DefaultNetworkID);
ResourceBuilderExtensions.cs (1)
869var endpointReference = new EndpointReference(resourceWithEndpoints, annotation, KnownNetworkIdentifiers.LocalhostNetwork);
Aspire.Hosting.Azure.AppConfiguration (1)
AzureAppConfigurationResource.cs (1)
19private EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.CosmosDB (1)
AzureCosmosDBResource.cs (1)
25internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.EventHubs (1)
AzureEventHubsResource.cs (1)
41internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.KeyVault (1)
AzureKeyVaultResource.cs (1)
37internal EndpointReference EmulatorEndpoint => new(this, "https");
Aspire.Hosting.Azure.ServiceBus (1)
AzureServiceBusResource.cs (1)
31internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.SignalR (1)
AzureSignalRResource.cs (1)
18internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.Storage (3)
AzureStorageResource.cs (3)
22private EndpointReference EmulatorBlobEndpoint => new(this, "blob"); 23private EndpointReference EmulatorQueueEndpoint => new(this, "queue"); 24private EndpointReference EmulatorTableEndpoint => new(this, "table");
Aspire.Hosting.Azure.Tests (1)
AzureStorageExtensionsTests.cs (1)
418=> new(storage.Resource, new EndpointAnnotation(ProtocolType.Tcp, name: name, targetPort: port));
Aspire.Hosting.DevTunnels (2)
DevTunnelResource.cs (1)
69TunnelEndpoint = new(targetEndpoint.Resource, TunnelEndpointAnnotation);
DevTunnelResourceBuilderExtensions.cs (1)
390return new EndpointReference(tunnelResource, endpointName)
Aspire.Hosting.Docker (2)
DockerComposeAspireDashboardResource.cs (2)
18public EndpointReference PrimaryEndpoint => new(this, "http"); 23public EndpointReference OtlpGrpcEndpoint => new(this, "otlp-grpc");
Aspire.Hosting.Garnet (1)
GarnetResource.cs (1)
29public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Kafka (2)
KafkaServerResource.cs (2)
26public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName); 42public EndpointReference InternalEndpoint => _internalEndpoint ??= new(this, InternalEndpointName);
Aspire.Hosting.Milvus (1)
MilvusServerResource.cs (1)
36public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.MongoDB (1)
MongoDBServerResource.cs (1)
34public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.MySql (1)
MySqlServerResource.cs (1)
26PrimaryEndpoint = new(this, PrimaryEndpointName);
Aspire.Hosting.Nats (1)
NatsServerResource.cs (1)
33public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Oracle (1)
OracleDatabaseServerResource.cs (1)
23PrimaryEndpoint = new(this, PrimaryEndpointName);
Aspire.Hosting.PostgreSQL (2)
PgWebContainerResource.cs (1)
21public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
PostgresServerResource.cs (1)
24PrimaryEndpoint = new(this, PrimaryEndpointName);
Aspire.Hosting.Qdrant (2)
QdrantServerResource.cs (2)
36public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName); 51public EndpointReference HttpEndpoint => _httpEndpoint ??= new(this, HttpEndpointName);
Aspire.Hosting.RabbitMQ (2)
RabbitMQServerResource.cs (2)
26PrimaryEndpoint = new(this, PrimaryEndpointName); 39public EndpointReference ManagementEndpoint => _managementEndpoint ??= new(this, ManagementEndpointName);
Aspire.Hosting.Redis (3)
RedisBuilderExtensions.cs (1)
269endpoint = new EndpointReference(redisInstance, secondaryEndpoint);
RedisInsightResource.cs (1)
21public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
RedisResource.cs (1)
38public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Seq (1)
SeqResource.cs (1)
19public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.SqlServer (1)
SqlServerServerResource.cs (1)
23PrimaryEndpoint = new(this, PrimaryEndpointName);
Aspire.Hosting.Tests (23)
Dashboard\DashboardLifecycleHookTests.cs (2)
140var httpEndpoint = new EndpointReference(dashboardResource, "http"); 142var otlpGrpcEndpoint = new EndpointReference(dashboardResource, DashboardEventHandlers.OtlpGrpcEndpointName);
EndpointReferenceTests.cs (17)
17var endpointRef = new EndpointReference(resource, annotation); 35var endpointRef = new EndpointReference(resource, annotation); 55var endpointRef = new EndpointReference(resource, annotation); 69var endpointRef = new EndpointReference(resource, annotation); 88var endpointRef = new EndpointReference(resource, annotation); 107var endpointRef = new EndpointReference(resource, annotation); 121var endpointRef = new EndpointReference(resource, annotation); 135var endpointRef = new EndpointReference(resource, annotation); 149var endpointRef = new EndpointReference(resource, annotation); 168var endpointRef = new EndpointReference(resource, annotation); 186var endpointRef = new EndpointReference(resource, annotation); 217var endpointRef = new EndpointReference(resource, annotation); 230var endpointRef = new EndpointReference(resource, annotation); 243var endpointRef = new EndpointReference(resource, annotation); 256var endpointRef = new EndpointReference(resource, annotation); 269var endpointRef = new EndpointReference(resource, annotation); 282var endpointRef = new EndpointReference(resource, annotation);
ExpressionResolverTests.cs (4)
264PrimaryEndpoint = new(this, "http", KnownNetworkIdentifiers.LocalhostNetwork); 284EndpointReference Endpoint1 => new(this, "endpoint1"); 285EndpointReference Endpoint2 => new(this, "endpoint2"); 286EndpointReference Endpoint3 => new(this, "endpoint3");
Aspire.Hosting.Valkey (1)
ValkeyResource.cs (1)
34public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
248 references to EndpointReference
Aspire.Hosting (72)
ApplicationModel\EndpointReference.cs (8)
186/// Creates a new instance of <see cref="EndpointReference"/> with the specified endpoint name. 193/// or host processes calling container via mapped ports). If a <see cref="NetworkIdentifier"/> is specified, the <see cref="EndpointReference"/> 209/// Creates a new instance of <see cref="EndpointReference"/> with the specified endpoint name. 218/// Creates a new instance of <see cref="EndpointReference"/> with the specified endpoint name. 240/// Creates a new instance of <see cref="EndpointReference"/> with the specified endpoint name. 254public class EndpointReferenceExpression(EndpointReference endpointReference, EndpointProperty property) : IManifestExpressionProvider, IValueProvider, IValueWithReferences 257/// Gets the <see cref="EndpointReference"/>. 259public EndpointReference Endpoint { get; } = endpointReference ?? throw new ArgumentNullException(nameof(endpointReference));
ApplicationModel\ExpressionResolver.cs (2)
12async Task<string?> ResolveInContainerContextAsync(EndpointReference endpointReference, EndpointProperty property, ValueProviderContext context) 104EndpointReference er when networkContext == KnownNetworkIdentifiers.DefaultAspireContainerNetwork => new ResolvedValue(await ResolveInContainerContextAsync(er, EndpointProperty.Url, context).ConfigureAwait(false), false),
ApplicationModel\HostUrl.cs (2)
64var targetEndpoint = model.Resources.Where(r => !r.IsContainer()) 69if (r.GetEndpoints(KnownNetworkIdentifiers.LocalhostNetwork).FirstOrDefault(ep => ep.Port == uri.Port) is EndpointReference ep)
ApplicationModel\HttpCommandContext.cs (4)
9/// or <see cref="ResourceBuilderExtensions.WithHttpCommand{TResource}(IResourceBuilder{TResource}, string, string, Func{EndpointReference}?, string?, HttpCommandOptions?)"/>. 26public required EndpointReference Endpoint { get; init; } 47/// or <see cref="ResourceBuilderExtensions.WithHttpCommand{TResource}(IResourceBuilder{TResource}, string, string, Func{EndpointReference}?, string?, HttpCommandOptions?)"/>. 64public required EndpointReference Endpoint { get; init; }
ApplicationModel\HttpCommandOptions.cs (1)
16public Func<EndpointReference>? EndpointSelector { get; set; }
ApplicationModel\IComputeEnvironmentResource.cs (2)
14/// Gets a <see cref="ReferenceExpression"/> representing the host address or host name for the specified <see cref="EndpointReference"/>. 22ReferenceExpression GetHostAddressExpression(EndpointReference endpointReference) => throw new NotImplementedException();
ApplicationModel\ProbeAnnotation.cs (1)
76public required EndpointReference EndpointReference { get; init; }
ApplicationModel\ProjectResource.cs (1)
108internal bool ShouldInjectEndpointEnvironment(EndpointReference e)
ApplicationModel\ResourceExtensions.cs (9)
699/// <returns>An enumeration of <see cref="EndpointReference"/> based on the <see cref="EndpointAnnotation"/> annotations from the resources' <see cref="IResource.Annotations"/> collection.</returns> 700public static IEnumerable<EndpointReference> GetEndpoints(this IResourceWithEndpoints resource) 715/// <returns>An enumeration of <see cref="EndpointReference"/> based on the <see cref="EndpointAnnotation"/> annotations from the resources' <see cref="IResource.Annotations"/> collection.</returns> 716public static IEnumerable<EndpointReference> GetEndpoints(this IResourceWithEndpoints resource, NetworkIdentifier contextNetworkID) 731/// <returns>An <see cref="EndpointReference"/>object providing resolvable reference for the specified endpoint.</returns> 732public static EndpointReference GetEndpoint(this IResourceWithEndpoints resource, string endpointName) 752/// <param name="contextNetworkID">The network ID of the network that provides the context for the returned <see cref="EndpointReference"/></param> 753/// <returns>An <see cref="EndpointReference"/>object providing resolvable reference for the specified endpoint.</returns> 754public static EndpointReference GetEndpoint(this IResourceWithEndpoints resource, string endpointName, NetworkIdentifier contextNetworkID)
ApplicationModel\ResourceUrlAnnotation.cs (2)
27public EndpointReference? Endpoint { get; init; } 41internal ResourceUrlAnnotation WithEndpoint(EndpointReference endpoint)
ApplicationModel\ResourceUrlsCallbackContext.cs (2)
28public EndpointReference? GetEndpoint(string name) => 41public EndpointReference? GetEndpoint(string name, NetworkIdentifier contextNetworkID) =>
Backchannel\AuxiliaryBackchannelRpcTarget.cs (1)
90var mcpEndpoint = dashboardResource.GetEndpoint(McpEndpointName);
Dashboard\DashboardEventHandlers.cs (6)
615static ReferenceExpression GetTargetUrlExpression(EndpointReference e) => 618var otlpGrpc = dashboardResource.GetEndpoint(OtlpGrpcEndpointName, KnownNetworkIdentifiers.LocalhostNetwork); 624var otlpHttp = dashboardResource.GetEndpoint(OtlpHttpEndpointName, KnownNetworkIdentifiers.LocalhostNetwork); 630var mcp = dashboardResource.GetEndpoint(McpEndpointName, KnownNetworkIdentifiers.LocalhostNetwork); 655foreach (var e in frontendEndpoints.Where(e => e.EndpointName is "http" or "https")) 671var publicEndpoint = frontendEndpoints.FirstOrDefault(e => e.EndpointName is "https") ?? frontendEndpoints.First(e => e.EndpointName is "http");
Orchestrator\ApplicationOrchestrator.cs (1)
236var endpointReference = new EndpointReference(resourceWithEndpoints, endpoint, endpoint.DefaultNetworkID);
ProjectResourceBuilderExtensions.cs (3)
904foreach (var e in builder.Resource.GetEndpoints().Where(builder.Resource.ShouldInjectEndpointEnvironment)) 953foreach (var e in builder.Resource.GetEndpoints().Where(builder.Resource.ShouldInjectEndpointEnvironment)) 984foreach (var e in builder.Resource.GetEndpoints().Where(builder.Resource.ShouldInjectEndpointEnvironment))
ResourceBuilderExtensions.cs (27)
144public static IResourceBuilder<T> WithEnvironment<T>(this IResourceBuilder<T> builder, string name, EndpointReference endpointReference) 402foreach (var endpoint in annotation.Resource.GetEndpoints(annotation.ContextNetworkID)) 711public static IResourceBuilder<TDestination> WithReference<TDestination>(this IResourceBuilder<TDestination> builder, EndpointReference endpointReference) 869var endpointReference = new EndpointReference(resourceWithEndpoints, annotation, KnownNetworkIdentifiers.LocalhostNetwork); 967/// Gets an <see cref="EndpointReference"/> by name from the resource. These endpoints are declared either using <see cref="WithEndpoint{T}(IResourceBuilder{T}, int?, int?, string?, string?, string?, bool, bool?, ProtocolType?)"/> or by launch settings (for project resources). 968/// The <see cref="EndpointReference"/> can be used to resolve the address of the endpoint in <see cref="WithEnvironment{T}(IResourceBuilder{T}, Action{EnvironmentCallbackContext})"/>. 974/// <returns>An <see cref="EndpointReference"/> that can be used to resolve the address of the endpoint after resource allocation has occurred.</returns> 975public static EndpointReference GetEndpoint<T>(this IResourceBuilder<T> builder, [EndpointName] string name, NetworkIdentifier contextNetworkID) where T : IResourceWithEndpoints 983/// Gets an <see cref="EndpointReference"/> by name from the resource. These endpoints are declared either using <see cref="WithEndpoint{T}(IResourceBuilder{T}, int?, int?, string?, string?, string?, bool, bool?, ProtocolType?)"/> or by launch settings (for project resources). 984/// The <see cref="EndpointReference"/> can be used to resolve the address of the endpoint in <see cref="WithEnvironment{T}(IResourceBuilder{T}, Action{EnvironmentCallbackContext})"/>. 989/// <returns>An <see cref="EndpointReference"/> that can be used to resolve the address of the endpoint after resource allocation has occurred.</returns> 990public static EndpointReference GetEndpoint<T>(this IResourceBuilder<T> builder, [EndpointName] string name) where T : IResourceWithEndpoints 1186var endpoint = url.ValueProviders.OfType<EndpointReference>().FirstOrDefault(); 1206/// To add another URL for an endpoint, use <see cref="WithUrlForEndpoint{T}(IResourceBuilder{T}, string, Func{EndpointReference, ResourceUrlAnnotation})"/>. 1279public static IResourceBuilder<T> WithUrlForEndpoint<T>(this IResourceBuilder<T> builder, string endpointName, Func<EndpointReference, ResourceUrlAnnotation> callback) 1284var endpoint = builder.GetEndpoint(endpointName); 1794public static IResourceBuilder<T> WithHttpHealthCheck<T>(this IResourceBuilder<T> builder, Func<EndpointReference>? endpointSelector, string? path = null, int? statusCode = null) where T : IResourceWithEndpoints 1798var endpoint = endpointSelector() 2143Func<EndpointReference>? endpointSelector, 2150var endpoint = endpointSelector() 2557private static Func<EndpointReference> NamedEndpointSelector<TResource>(IResourceBuilder<TResource> builder, string[] endpointNames, string errorDisplayNoun) 2563EndpointReference? matchingEndpoint = null; 2583private static Func<EndpointReference> DefaultEndpointSelector<TResource>(IResourceBuilder<TResource> builder) 2589EndpointReference? matchingEndpoint = null; 3022public static IResourceBuilder<T> WithHttpProbe<T>(this IResourceBuilder<T> builder, ProbeType type, Func<EndpointReference>? endpointSelector, string? path = null, int? initialDelaySeconds = null, int? periodSeconds = null, int? timeoutSeconds = null, int? failureThreshold = null, int? successThreshold = null) 3027var endpoint = endpointSelector() ?? throw new DistributedApplicationException($"Could not create HTTP probe for resource '{builder.Resource.Name}' as the endpoint selector returned null.");
Aspire.Hosting.Azure (6)
AzureBicepResourceExtensions.cs (1)
301public static IResourceBuilder<T> WithParameter<T>(this IResourceBuilder<T> builder, string name, EndpointReference value)
AzureProvisioningResourceExtensions.cs (4)
215/// The <see cref="EndpointReference"/> to use for the value of the <see cref="ProvisioningParameter"/>. 223/// This is useful when assigning a <see cref="BicepValue"/> to the value of an Aspire <see cref="EndpointReference"/>. 225public static ProvisioningParameter AsProvisioningParameter(this EndpointReference endpointReference, AzureResourceInfrastructure infrastructure, string parameterName) 249/// This is useful when assigning a <see cref="BicepValue"/> to the value of an Aspire <see cref="EndpointReference"/>.
AzureResourcePreparer.cs (1)
410if (value is string or EndpointReference or ParameterResource or EndpointReferenceExpression or HostUrl)
Aspire.Hosting.Azure.AppConfiguration (1)
AzureAppConfigurationResource.cs (1)
19private EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.AppContainers (2)
AzureContainerAppEnvironmentResource.cs (1)
196ReferenceExpression IComputeEnvironmentResource.GetHostAddressExpression(EndpointReference endpointReference)
BaseContainerAppContext.cs (1)
222if (value is EndpointReference ep)
Aspire.Hosting.Azure.AppService (2)
AzureAppServiceEnvironmentResource.cs (1)
224ReferenceExpression IComputeEnvironmentResource.GetHostAddressExpression(EndpointReference endpointReference)
AzureAppServiceWebsiteContext.cs (1)
135if (value is EndpointReference ep)
Aspire.Hosting.Azure.CosmosDB (2)
AzureCosmosDBEmulatorConnectionString.cs (1)
11public static ReferenceExpression Create(EndpointReference endpoint, bool isPreviewEmulator) =>
AzureCosmosDBResource.cs (1)
25internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.EventHubs (3)
AzureEventHubsExtensions.cs (2)
263var blobEndpoint = storage.GetEndpoint("blob"); 264var tableEndpoint = storage.GetEndpoint("table");
AzureEventHubsResource.cs (1)
41internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.Functions (2)
AzureFunctionsProjectResourceExtensions.cs (2)
224var endpoint = resource.GetEndpoint("http"); 310var targetEndpoint = builder.Resource.GetEndpoint(useHttps ? "https" : "http");
Aspire.Hosting.Azure.KeyVault (1)
AzureKeyVaultResource.cs (1)
37internal EndpointReference EmulatorEndpoint => new(this, "https");
Aspire.Hosting.Azure.Kusto (1)
AzureKustoClusterResource.cs (1)
54var endpoint = this.GetEndpoint("http");
Aspire.Hosting.Azure.ServiceBus (2)
AzureServiceBusExtensions.cs (1)
384var sqlEndpoint = sqlServerResource.Resource.GetEndpoint("tcp");
AzureServiceBusResource.cs (1)
31internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.SignalR (1)
AzureSignalRResource.cs (1)
18internal EndpointReference EmulatorEndpoint => new(this, "emulator");
Aspire.Hosting.Azure.Storage (7)
AzureStorageEmulatorConnectionString.cs (4)
13public static ReferenceExpression Create(EndpointReference? blobEndpoint = null, EndpointReference? queueEndpoint = null, EndpointReference? tableEndpoint = null) 33static void AppendEndpointExpression(ReferenceExpressionBuilder builder, string key, EndpointReference endpoint)
AzureStorageResource.cs (3)
22private EndpointReference EmulatorBlobEndpoint => new(this, "blob"); 23private EndpointReference EmulatorQueueEndpoint => new(this, "queue"); 24private EndpointReference EmulatorTableEndpoint => new(this, "table");
Aspire.Hosting.Azure.Tests (13)
AzureContainerAppsTests.cs (6)
307var httpEp = project.GetEndpoint("http"); 308var httpsEp = project.GetEndpoint("https"); 309var internalEp = project.GetEndpoint("internal"); 384var httpEp = project.GetEndpoint("http"); 385var httpsEp = project.GetEndpoint("https"); 386var internalEp = project.GetEndpoint("internal");
AzureCosmosDBExtensionsTests.cs (1)
84var endpoint = cosmos.GetEndpoint("data-explorer");
AzureProvisioningResourceExtensionsTests.cs (1)
20var endpointReference = apiProject.GetEndpoint("https");
AzureStorageExtensionsTests.cs (1)
417EndpointReference GetEndpointReference(string name, int port)
src\Aspire.Hosting.Azure.Storage\AzureStorageEmulatorConnectionString.cs (4)
13public static ReferenceExpression Create(EndpointReference? blobEndpoint = null, EndpointReference? queueEndpoint = null, EndpointReference? tableEndpoint = null) 33static void AppendEndpointExpression(ReferenceExpressionBuilder builder, string key, EndpointReference endpoint)
Aspire.Hosting.DevTunnels (17)
DevTunnelResource.cs (3)
57EndpointReference targetEndpoint, 81internal EndpointReference TunnelEndpoint { get; } 83internal EndpointReference TargetEndpoint { get; init; }
DevTunnelResourceBuilderExtensions.cs (14)
240/// To expose only specific endpoints on the referenced resource, use <see cref="WithReference(IResourceBuilder{DevTunnelResource}, EndpointReference, DevTunnelPortOptions?)"/>. 255foreach (var endpoint in resourceBuilder.Resource.GetEndpoints()) 272EndpointReference targetEndpoint) 284EndpointReference targetEndpoint, 297EndpointReference targetEndpoint, 329/// <returns>An <see cref="EndpointReference"/> representing the public tunnel endpoint.</returns> 331public static EndpointReference GetEndpoint<TResource>(this IResourceBuilder<DevTunnelResource> tunnelBuilder, IResourceBuilder<TResource> resourceBuilder, string endpointName) 347/// <returns>An <see cref="EndpointReference"/> representing the public tunnel endpoint.</returns> 348public static EndpointReference GetEndpoint(this IResourceBuilder<DevTunnelResource> tunnelBuilder, IResource resource, string endpointName) 370/// <returns>An <see cref="EndpointReference"/> representing the public tunnel endpoint.</returns> 371public static EndpointReference GetEndpoint(this IResourceBuilder<DevTunnelResource> tunnelBuilder, EndpointReference targetEndpointReference) 388private static EndpointReference CreateEndpointReferenceWithError(DevTunnelResource tunnelResource, IResource targetResource, string endpointName) 456EndpointReference targetEndpoint,
Aspire.Hosting.DevTunnels.Tests (10)
DevTunnelResourceBuilderExtensionsTests.cs (10)
83var tunnelEndpoint = tunnel.GetEndpoint(target.Resource, "https"); 100var tunnelEndpoint = tunnel.GetEndpoint(target, "https"); 117var targetEndpoint = target.GetEndpoint("https"); 118var tunnelEndpoint = tunnel.GetEndpoint(targetEndpoint); 135var endpointRef = tunnel.GetEndpoint(target.Resource, "nonexistent"); 156var target2Endpoint = target2.GetEndpoint("https"); 157var endpointRef = tunnel.GetEndpoint(target2Endpoint); 175var endpointRef = tunnel.GetEndpoint(target.Resource, "https"); 195var httpTunnelEndpoint = tunnel.GetEndpoint(target.Resource, "http"); 196var httpsTunnelEndpoint = tunnel.GetEndpoint(target.Resource, "https");
Aspire.Hosting.Docker (8)
DockerComposeAspireDashboardResource.cs (2)
18public EndpointReference PrimaryEndpoint => new(this, "http"); 23public EndpointReference OtlpGrpcEndpoint => new(this, "otlp-grpc");
DockerComposeEnvironmentContext.cs (1)
116.Where(kvp => kvp.Value is EndpointReference epRef && epRef.Scheme == "https" && kvp.Key.StartsWith("services__"))
DockerComposeEnvironmentResource.cs (2)
177/// Computes the host URL <see cref="ReferenceExpression"/> for the given <see cref="EndpointReference"/>. 181ReferenceExpression IComputeEnvironmentResource.GetHostAddressExpression(EndpointReference endpointReference)
DockerComposeInfrastructure.cs (2)
53if (environment.DashboardEnabled && environment.Dashboard?.Resource.OtlpGrpcEndpoint is EndpointReference otlpGrpcEndpoint) 81private static void ConfigureOtlp(IResource resource, EndpointReference otlpEndpoint)
DockerComposeServiceResourceExtensions.cs (1)
20if (value is EndpointReference ep)
Aspire.Hosting.Garnet (2)
GarnetResource.cs (2)
24private EndpointReference? _primaryEndpoint; 29public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.JavaScript (1)
JavaScriptHostingExtensions.cs (1)
521var targetEndpoint = resource.GetEndpoint("https");
Aspire.Hosting.Kafka (8)
KafkaBuilderExtensions.cs (4)
120var endpoint = kafkaResource.InternalEndpoint; 135static void ConfigureKafkaUIContainer(EnvironmentCallbackContext context, EndpointReference endpoint, int index) 211var primaryEndpoint = resource.PrimaryEndpoint; 213var internalEndpoint = resource.InternalEndpoint;
KafkaServerResource.cs (4)
19private EndpointReference? _primaryEndpoint; 20private EndpointReference? _internalEndpoint; 26public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName); 42public EndpointReference InternalEndpoint => _internalEndpoint ??= new(this, InternalEndpointName);
Aspire.Hosting.Kubernetes (3)
KubernetesEnvironmentResource.cs (2)
103/// Computes the host URL <see cref="ReferenceExpression"/> for the given <see cref="EndpointReference"/>. 107ReferenceExpression IComputeEnvironmentResource.GetHostAddressExpression(EndpointReference endpointReference)
KubernetesResource.cs (1)
363if (value is EndpointReference ep)
Aspire.Hosting.Milvus (2)
MilvusServerResource.cs (2)
26private EndpointReference? _primaryEndpoint; 36public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.MongoDB (2)
MongoDBServerResource.cs (2)
17private EndpointReference? _primaryEndpoint; 34public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.MySql (3)
MySqlBuilderExtensions.cs (2)
253var endpoint = singleInstance.PrimaryEndpoint; 393var endpoint = mySqlInstance.PrimaryEndpoint;
MySqlServerResource.cs (1)
33public EndpointReference PrimaryEndpoint { get; }
Aspire.Hosting.Nats (2)
NatsServerResource.cs (2)
16private EndpointReference? _primaryEndpoint; 33public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Oracle (1)
OracleDatabaseServerResource.cs (1)
30public EndpointReference PrimaryEndpoint { get; }
Aspire.Hosting.PostgreSQL (4)
PgWebContainerResource.cs (2)
16private EndpointReference? _primaryEndpoint; 21public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
PostgresBuilderExtensions.cs (1)
548var endpoint = postgresInstance.PrimaryEndpoint;
PostgresServerResource.cs (1)
32public EndpointReference PrimaryEndpoint { get; }
Aspire.Hosting.Python (1)
PythonAppResourceBuilderExtensions.cs (1)
280var endpoint = ((IResourceWithEndpoints)c.Resource).GetEndpoint("http");
Aspire.Hosting.Qdrant (4)
QdrantServerResource.cs (4)
25private EndpointReference? _primaryEndpoint; 26private EndpointReference? _httpEndpoint; 36public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName); 51public EndpointReference HttpEndpoint => _httpEndpoint ??= new(this, HttpEndpointName);
Aspire.Hosting.RabbitMQ (3)
RabbitMQServerResource.cs (3)
14private EndpointReference? _managementEndpoint; 34public EndpointReference PrimaryEndpoint { get; } 39public EndpointReference ManagementEndpoint => _managementEndpoint ??= new(this, ManagementEndpointName);
Aspire.Hosting.Redis (5)
RedisBuilderExtensions.cs (1)
263var endpoint = redisInstance.PrimaryEndpoint;
RedisInsightResource.cs (2)
16private EndpointReference? _primaryEndpoint; 21public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
RedisResource.cs (2)
33private EndpointReference? _primaryEndpoint; 38public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Redis.Tests (2)
RedisFunctionalTests.cs (2)
84var endpoint = redis.GetEndpoint(RedisResource.PrimaryEndpointName); 630var endpoint = redisCommander.GetEndpoint("http");
Aspire.Hosting.Seq (2)
SeqResource.cs (2)
14private EndpointReference? _primaryEndpoint; 19public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.SqlServer (1)
SqlServerServerResource.cs (1)
30public EndpointReference PrimaryEndpoint { get; }
Aspire.Hosting.Testing (3)
DistributedApplicationHostingTestingExtensions.cs (3)
116EndpointReference? endpoint; 143static EndpointReference? GetEndpointOrDefault(IResourceWithEndpoints resourceWithEndpoints, string endpointName, NetworkIdentifier? networkIdentifier = default) 145var reference = resourceWithEndpoints.GetEndpoint(endpointName, networkIdentifier ?? KnownNetworkIdentifiers.LocalhostNetwork);
Aspire.Hosting.Tests (34)
Dashboard\DashboardLifecycleHookTests.cs (2)
140var httpEndpoint = new EndpointReference(dashboardResource, "http"); 142var otlpGrpcEndpoint = new EndpointReference(dashboardResource, DashboardEventHandlers.OtlpGrpcEndpointName);
EndpointReferenceTests.cs (17)
17var endpointRef = new EndpointReference(resource, annotation); 35var endpointRef = new EndpointReference(resource, annotation); 55var endpointRef = new EndpointReference(resource, annotation); 69var endpointRef = new EndpointReference(resource, annotation); 88var endpointRef = new EndpointReference(resource, annotation); 107var endpointRef = new EndpointReference(resource, annotation); 121var endpointRef = new EndpointReference(resource, annotation); 135var endpointRef = new EndpointReference(resource, annotation); 149var endpointRef = new EndpointReference(resource, annotation); 168var endpointRef = new EndpointReference(resource, annotation); 186var endpointRef = new EndpointReference(resource, annotation); 217var endpointRef = new EndpointReference(resource, annotation); 230var endpointRef = new EndpointReference(resource, annotation); 243var endpointRef = new EndpointReference(resource, annotation); 256var endpointRef = new EndpointReference(resource, annotation); 269var endpointRef = new EndpointReference(resource, annotation); 282var endpointRef = new EndpointReference(resource, annotation);
ExpressionResolverTests.cs (4)
267public EndpointReference PrimaryEndpoint { get; } 284EndpointReference Endpoint1 => new(this, "endpoint1"); 285EndpointReference Endpoint2 => new(this, "endpoint2"); 286EndpointReference Endpoint3 => new(this, "endpoint3");
ProjectResourceTests.cs (2)
653var http = resource.GetEndpoint("http"); 654var https = resource.GetEndpoint("https");
WithEndpointTests.cs (3)
235var ep0 = container.GetEndpoint("ep0"); 236var ep1 = container.GetEndpoint("ep1"); 237var ep2 = container.GetEndpoint("ep2");
WithEnvironmentTests.cs (4)
233var endpoint = container.GetEndpoint("primary"); 282var endpoint = container.GetEndpoint("primary"); 317var endpoint = container.GetEndpoint("primary"); 450var endpoint = container.GetEndpoint("primary");
WithUrlsTests.cs (2)
376var httpEndpoint = servicea.Resource.GetEndpoint("http"); 401var httpEndpoint = servicea.Resource.GetEndpoint("http");
Aspire.Hosting.Valkey (2)
ValkeyResource.cs (2)
14private EndpointReference? _primaryEndpoint; 34public EndpointReference PrimaryEndpoint => _primaryEndpoint ??= new(this, PrimaryEndpointName);
Aspire.Hosting.Yarp (5)
ConfigurationBuilder\IYarpConfigurationBuilder.cs (3)
27public YarpCluster AddCluster(EndpointReference endpoint); 87public static YarpRoute AddRoute(this IYarpConfigurationBuilder builder, EndpointReference endpoint) 110public static YarpRoute AddRoute(this IYarpConfigurationBuilder builder, string path, EndpointReference endpoint)
ConfigurationBuilder\YarpCluster.cs (1)
25internal YarpCluster(EndpointReference endpoint)
ConfigurationBuilder\YarpConfigurationBuilder.cs (1)
27public YarpCluster AddCluster(EndpointReference endpoint)
Aspire.Hosting.Yarp.Tests (6)
YarpClusterTests.cs (4)
27var httpEndpoint = resource.GetEndpoint("testendpoint"); 28var httpsEndpoint = resource.GetEndpoint("anotherendpoint"); 45var httpEndpoint = resource.GetEndpoint("http"); 46var httpsEndpoint = resource.GetEndpoint("https");
YarpFunctionalTests.cs (2)
27private async Task VerifyYarpResource(Action<IResourceBuilder<YarpResource>, EndpointReference> configurator) 51var endpoint = yarp.Resource.GetEndpoint("http");
AspireWithNode.AppHost (1)
AppHost.cs (1)
39var httpsEndpoint = frontend.GetEndpoint("https");
DevTunnels.AppHost (1)
AppHost.cs (1)
18var devTunnelPortEndpoint = privateDevTunnel.GetEndpoint(api, "https");