Implemented interface member:
method
GetValueAsync
Aspire.Hosting.ApplicationModel.IValueProvider.GetValueAsync(System.Threading.CancellationToken)
67 references to GetValueAsync
Aspire.Hosting (1)
ApplicationModel\EndpointReference.cs (1)
149public ValueTask<string?> GetValueAsync(CancellationToken cancellationToken = default) => Property(EndpointProperty.Url).GetValueAsync(cancellationToken);
Aspire.Hosting.Azure.EntraId.Tests (1)
EntraIdProvisioningTests.cs (1)
1344var pendingOrigin = web.GetEndpoint("https").BrowserOrigins.GetValueAsync(cts.Token).AsTask();
Aspire.Hosting.DevTunnels (1)
DevTunnelResource.cs (1)
124resolvedTargetPort = await TargetEndpoint.Property(property).GetValueAsync(cancellationToken).ConfigureAwait(false);
Aspire.Hosting.DevTunnels.Tests (4)
DevTunnelMonitorTests.cs (4)
282Assert.Equal("https://custom.example,https://original-3000.usw2.devtunnels.ms", await origin.GetValueAsync(ct)); 290await endpoint.BrowserOrigins.GetValueAsync()); 300Assert.Equal("https://custom.example,https://replacement-3000.usw2.devtunnels.ms", await origin.GetValueAsync()); 303await endpoint.BrowserOrigins.GetValueAsync());
Aspire.Hosting.Maui (1)
MauiOtlpExtensions.cs (1)
377portValue = await endpointReference.Property(property).GetValueAsync(cancellationToken).ConfigureAwait(false);
Aspire.Hosting.MongoDB (1)
ReplicaSet\MongoDBReplicaSetBuilderExtensions.cs (1)
163.GetValueAsync(ct)
Aspire.Hosting.Tests (58)
ConditionalReferenceExpressionTests.cs (4)
252var value = await tlsExpr.GetValueAsync(); 269var value = await tlsExpr.GetValueAsync(); 296Assert.Equal(bool.FalseString, await tlsExpr.GetValueAsync()); 299Assert.Equal(bool.TrueString, await tlsExpr.GetValueAsync());
Dcp\DcpExecutorTests.cs (3)
5016Assert.Equal(allocatedPort.ToString(CultureInfo.InvariantCulture), await database.GetEndpoint("NoPortTargetPortSet").Property(EndpointProperty.Port).GetValueAsync()); 5215Assert.Equal($"https://frontend.example,{frontend.GetEndpoint("http").Url}", await frontend.GetEndpoint("http").BrowserOrigins.GetValueAsync(ct)); 5216Assert.Equal($"https://backend.example,{backend.GetEndpoint("http").Url}", await backend.GetEndpoint("http").BrowserOrigins.GetValueAsync(ct));
EndpointReferenceTests.cs (29)
76var getValueTask = endpointExpr.GetValueAsync(CancellationToken.None); 96var url = await endpointExpr.GetValueAsync(CancellationToken.None); 110var getValueTask = hostExpr.GetValueAsync(CancellationToken.None); 129var getValueTask = portExpr.GetValueAsync(CancellationToken.None); 148var scheme = await schemeExpr.GetValueAsync(CancellationToken.None); 162var ipv4 = await ipv4Expr.GetValueAsync(CancellationToken.None); 176var targetPort = await targetPortExpr.GetValueAsync(CancellationToken.None); 190var getValueTask = targetPortExpr.GetValueAsync(CancellationToken.None); 210var getValueTask = endpointExpr.GetValueAsync(cts.Token); 229var task1 = expr1.GetValueAsync(CancellationToken.None); 230var task2 = expr2.GetValueAsync(CancellationToken.None); 231var task3 = expr3.GetValueAsync(CancellationToken.None); 533Assert.Equal("https://public.example,https://alias.example,https://localhost:8443", await endpoint.BrowserOrigins.GetValueAsync()); 534Assert.Equal("https://public.example", await endpoint.PrimaryBrowserOrigin.GetValueAsync()); 548Assert.Equal(expected, await endpoint.BrowserOrigins.GetValueAsync()); 549Assert.Equal(expected, await endpoint.PrimaryBrowserOrigin.GetValueAsync()); 561Assert.Equal("https://frontend.example", await endpoint.BrowserOrigins.GetValueAsync()); 565Assert.Equal("https://frontend.example,https://replacement.example", await endpoint.BrowserOrigins.GetValueAsync()); 566Assert.Equal("https://frontend.example", await endpoint.PrimaryBrowserOrigin.GetValueAsync()); 578Assert.Equal("http://frontend.example", await resource.GetEndpoint("HTTP").BrowserOrigins.GetValueAsync()); 579Assert.Equal("https://separate.example", await resource.GetEndpoint("https").BrowserOrigins.GetValueAsync()); 591Assert.Equal("https://public.example", await host.BrowserOrigins.GetValueAsync()); 592Assert.Equal("https://public.example", await container.BrowserOrigins.GetValueAsync()); 593Assert.Equal("https://public.example", await host.PrimaryBrowserOrigin.GetValueAsync()); 615Assert.Equal(expected, await endpoint.Property(property).GetValueAsync()); 630Assert.Equal(expected, await endpoint.BrowserOrigins.GetValueAsync()); 631Assert.Equal(expected, await endpoint.PrimaryBrowserOrigin.GetValueAsync()); 642var value = resource.GetEndpoint("http").Property(property).GetValueAsync(cts.Token); 684Assert.Equal("https://local.example", await origin.GetValueAsync());
Orchestrator\ApplicationOrchestratorTests.cs (22)
37await requested.GetEndpoint("http").BrowserOrigins.GetValueAsync(context.CancellationToken); 54await first.GetEndpoint("http").BrowserOrigins.GetValueAsync(cts.Token)); 59Assert.Equal("http://localhost:8080", await second.GetEndpoint("http").BrowserOrigins.GetValueAsync(cts.Token)); 72observed = await first.GetEndpoint("http").BrowserOrigins.GetValueAsync(context.CancellationToken); 88Assert.Equal("http://localhost:8080", await second.GetEndpoint("http").BrowserOrigins.GetValueAsync()); 105var read = second.GetEndpoint("http").BrowserOrigins.GetValueAsync(context.CancellationToken).AsTask(); 152var pending = other.GetEndpoint("http").BrowserOrigins.GetValueAsync(cts.Token).AsTask(); 180observed = await endpoint.BrowserOrigins.GetValueAsync(ct); 189Assert.Equal(origins, await endpoint.BrowserOrigins.GetValueAsync(default)); 215await endpoint.BrowserOrigins.GetValueAsync(default)); 244var origin = await browserEndpoint.GetValueAsync(ct); 314var pendingOrigin = browserEndpoint.GetValueAsync(); 322Assert.Equal(expectedOrigins, await browserEndpoint.GetValueAsync()); 362Assert.Equal("https://admin.example,https://frontend.example,http://localhost:8080", await frontend.GetEndpoint("http").BrowserOrigins.GetValueAsync()); 386var pendingOrigin = frontend.GetEndpoint("http").BrowserOrigins.GetValueAsync(); 426Assert.Equal("https://frontend.example,http://localhost:8080", await origins.GetValueAsync()); 444var pendingOrigin = browserEndpoint.GetValueAsync(); 473Assert.Equal("http://localhost:8080", await frontend.GetEndpoint("http").BrowserOrigins.GetValueAsync().DefaultTimeout()); 474Assert.Equal("https://frontend.example,https://localhost:8443", await frontend.GetEndpoint("https").BrowserOrigins.GetValueAsync().DefaultTimeout()); 494Assert.Equal("http://localhost:8080", await frontend.GetEndpoint("http").BrowserOrigins.GetValueAsync()); 521await Assert.ThrowsAsync<InvalidOperationException>(async () => await browserEndpoint.GetValueAsync()); 526Assert.Equal("https://frontend.example,http://localhost:8080", await browserEndpoint.GetValueAsync());