1 write to Name
Aspire.Hosting (1)
139 references to Name
Aspire.Hosting (34)
Dcp\DcpExecutor.cs (18)
968throw new InvalidOperationException($"Service '{svc.Metadata.Name}' needs to specify a port for endpoint '{sp.EndpointAnnotation.Name}' since it isn't using a proxy.");
1017StringComparers.EndpointAnnotationName.Equals(swr.EndpointAnnotation.Name, endpoint.Name)
1022throw new InvalidDataException($"The '{endpoint.Name}' on resource '{ts.ResourceName}' should have an associated DCP Service resource already set up");
1117svc.Annotate(CustomResource.EndpointNameAnnotation, endpoint.Name);
1167if (!processedEndpoints.Add((re.Resource.Name, endpoint.Name)))
1177endpoint.Name,
1185endpoint.Name,
1199StringComparers.EndpointAnnotationName.Equals(swr.EndpointAnnotation.Name, endpoint.Name)
1204throw new InvalidDataException($"Host endpoint '{endpoint.Name}' on resource '{re.Resource.Name}' should have an associated DCP Service resource already set up");
1223svc.Annotate(CustomResource.EndpointNameAnnotation, endpoint.Name);
2233throw new InvalidOperationException($"The endpoint '{ea.Name}' for container resource '{modelResourceName}' must specify the {nameof(EndpointAnnotation.TargetPort)} value");
2240throw new InvalidOperationException($"Resource '{modelResourceName}' uses multiple replicas and a proxy-less endpoint '{ea.Name}'. These features do not work together.");
2245throw new InvalidOperationException($"The endpoint '{ea.Name}' for resource '{modelResourceName}' is not using a proxy, and it has a value of {nameof(EndpointAnnotation.Port)} property that is different from the value of {nameof(EndpointAnnotation.TargetPort)} property. For proxy-less endpoints they must match.");
2255$"The endpoint '{ea.Name}' for resource '{modelResourceName}' requested a proxy ({nameof(ea.IsProxied)} is true). Non-container resources cannot be proxied when both {nameof(ea.TargetPort)} and {nameof(ea.Port)} are specified with the same value.");
2261$"Resource '{modelResourceName}' can have multiple replicas, and it uses endpoint '{ea.Name}' that has {nameof(ea.TargetPort)} property set. Each replica must have a unique port; setting {nameof(ea.TargetPort)} is not allowed.");
2808endpoint = endpoints.FirstOrDefault(e => StringComparers.EndpointAnnotationName.Equals(e.Name, endpointName));
Aspire.Hosting.Azure.AppContainers (5)
ContainerAppContext.cs (5)
153throw new NotSupportedException($"The endpoint(s) {string.Join(", ", unsupportedEndpoints.Select(r => $"'{r.Endpoint.Name}'"))} specify an unsupported scheme. The supported schemes are 'http', 'https', and 'tcp'.");
232throw new NotSupportedException($"The endpoint '{endpoint.Name}' is an http endpoint and must use port 80");
237throw new NotSupportedException($"The endpoint '{endpoint.Name}' is an https endpoint and must use port 443");
243_endpointMapping[endpoint.Name] = new(endpoint.UriScheme, NormalizedContainerAppName, port, targetPort, true, httpIngress.External);
264_endpointMapping[endpoint.Name] = new(endpoint.UriScheme, NormalizedContainerAppName, resolved.ExposedPort.Value ?? g.Port.Value, g.Port.Value, false, g.External);
Aspire.Hosting.Azure.AppService (3)
Aspire.Hosting.Azure.Kusto.Tests (2)
Aspire.Hosting.Azure.Tests (6)
Aspire.Hosting.DevTunnels (2)
Aspire.Hosting.Docker (2)
Aspire.Hosting.Garnet.Tests (2)
Aspire.Hosting.Kafka.Tests (4)
Aspire.Hosting.Keycloak.Tests (4)
Aspire.Hosting.Kubernetes (5)
Aspire.Hosting.Milvus.Tests (5)
Aspire.Hosting.MongoDB.Tests (2)
Aspire.Hosting.MySql.Tests (2)
Aspire.Hosting.Nats.Tests (2)
Aspire.Hosting.Oracle.Tests (3)
Aspire.Hosting.PostgreSQL.Tests (3)
Aspire.Hosting.Qdrant.Tests (8)
Aspire.Hosting.RabbitMQ.Tests (4)
Aspire.Hosting.Redis (1)
Aspire.Hosting.Redis.Tests (2)
Aspire.Hosting.Seq.Tests (4)
Aspire.Hosting.SqlServer.Tests (1)
Aspire.Hosting.Tests (29)
KestrelConfigTests.cs (10)
28Assert.Equal("http", a.Name);
34Assert.Equal("ExplicitHttp", a.Name);
64Assert.Equal("http", a.Name);
70Assert.Equal("ExplicitHttp", a.Name);
97Assert.Equal("https", a.Name);
114Assert.Equal("FirstHttpEndpoint", a.Name);
122Assert.Equal("SecondHttpEndpoint", a.Name);
283.WithEndpointsInEnvironment(e => e.Name != "FirstHttpEndpoint")
284.WithEndpointsInEnvironment(e => e.Name != "ExplicitProxiedHttp");
456endpoint.AllocatedEndpoint = new AllocatedEndpoint(endpoint, "localhost", endpoint.Port ?? 0, targetPortExpression: $"port_{endpoint.Name}");
Aspire.Hosting.Valkey.Tests (2)
Aspire.Hosting.Yarp.Tests (1)
TestProject.AppHost (1)