32 references to EndpointAnnotation
Aspire.Hosting (18)
ApplicationModel\EndpointReference.cs (4)
113public int? TargetPort => EndpointAnnotation.TargetPort; 123public string Scheme => EndpointAnnotation.UriScheme; 131EndpointAnnotation.AllocatedEndpointSnapshot; 296var nes = Endpoint.EndpointAnnotation.AllAllocatedEndpoints.Where(nes => nes.NetworkID == networkContext).FirstOrDefault();
ApplicationModel\ProjectResource.cs (1)
75var endpoint = e.EndpointAnnotation;
Dashboard\DashboardEventHandlers.cs (2)
613ReferenceExpression.Create($"{e.Property(EndpointProperty.Scheme)}://{e.EndpointAnnotation.TargetHost}:{e.Property(EndpointProperty.TargetPort)}"); 659aspnetCoreUrls.Append($"{e.Property(EndpointProperty.Scheme)}://{e.EndpointAnnotation.TargetHost}:{e.Property(EndpointProperty.TargetPort)}");
Orchestrator\ApplicationOrchestrator.cs (2)
264if (additionalUrl is not null && EndpointHostHelpers.IsLocalhostTld(additionalUrl.Endpoint?.EndpointAnnotation.TargetHost)) 363if (url.Endpoint?.EndpointAnnotation == primaryLaunchProfileEndpoint && !string.Equals(url.Url, primaryUrl.Url, StringComparisons.Url))
ProjectResourceBuilderExtensions.cs (9)
911if (!processedHttpsPort && e.EndpointAnnotation.UriScheme == "https") 920aspnetCoreUrls.Append($"{e.Property(EndpointProperty.Scheme)}://{e.EndpointAnnotation.TargetHost}:{e.Property(EndpointProperty.TargetPort)}"); 956if (e.EndpointAnnotation.UriScheme == scheme && e.EndpointAnnotation != builder.Resource.DefaultHttpsEndpoint) 958Debug.Assert(!e.EndpointAnnotation.FromLaunchProfile, "Endpoints from launch profile should never make it here"); 987if (e.EndpointAnnotation == builder.Resource.DefaultHttpsEndpoint) 995builder.Resource.KestrelEndpointAnnotationHosts.TryGetValue(e.EndpointAnnotation, out var kestrelHost) ? kestrelHost : "*"; 997var url = ReferenceExpression.Create($"{e.EndpointAnnotation.UriScheme}://{host}:{e.Property(EndpointProperty.TargetPort)}"); 1000context.EnvironmentVariables[$"Kestrel__Endpoints__{e.EndpointAnnotation.Name}__Url"] = url;
Aspire.Hosting.Azure.AppContainers (1)
AzureContainerAppEnvironmentResource.cs (1)
200if (!endpointReference.EndpointAnnotation.IsExternal)
Aspire.Hosting.DevTunnels.Tests (5)
DevTunnelResourceBuilderExtensionsTests.cs (5)
137var ex = Assert.Throws<InvalidOperationException>(() => _ = endpointRef.EndpointAnnotation); 159var ex = Assert.Throws<InvalidOperationException>(() => _ = endpointRef.EndpointAnnotation); 177var ex = Assert.Throws<InvalidOperationException>(() => _ = endpointRef.EndpointAnnotation); 201Assert.NotSame(httpTunnelEndpoint.EndpointAnnotation, httpsTunnelEndpoint.EndpointAnnotation);
Aspire.Hosting.Python (1)
PythonAppResourceBuilderExtensions.cs (1)
286c.Args.Add(endpoint.EndpointAnnotation.TargetHost);
Aspire.Hosting.Tests (7)
Dashboard\DashboardLifecycleHookTests.cs (4)
141httpEndpoint.EndpointAnnotation.AllocatedEndpoint = new(httpEndpoint.EndpointAnnotation, "localhost", 8080); 143otlpGrpcEndpoint.EndpointAnnotation.AllocatedEndpoint = new(otlpGrpcEndpoint.EndpointAnnotation, "localhost", 4317);
WithEndpointTests.cs (3)
239Assert.False(ep0.EndpointAnnotation.IsExternal); 240Assert.True(ep1.EndpointAnnotation.IsExternal); 241Assert.True(ep2.EndpointAnnotation.IsExternal);