37 instantiations of UrlSnapshot
Aspire.Hosting (5)
Dcp\ResourceSnapshotBuilder.cs (3)
583new(Name: endpointUrl.Endpoint!.EndpointName, 612new(Name: endpointName, Url: endpointUrl.Url, IsInternal: endpointUrl.IsInternal) 623new(Name: null, Url: url.Url, IsInternal: url.IsInternal)
ExternalServiceBuilderExtensions.cs (1)
186return urlSnapshots.Add(new(Name: null, uri.ToString(), IsInternal: false));
Orchestrator\ApplicationOrchestrator.cs (1)
223urls = resourceUrls.Select(url => new UrlSnapshot(Name: url.Endpoint?.EndpointName, Url: url.Url, IsInternal: url.DisplayLocation == UrlDisplayLocation.DetailsOnly)
Aspire.Hosting.Azure (3)
Provisioning\Provisioners\BicepProvisioner.cs (3)
122portalUrls.Add(new(Name: DeploymentUrlName, Url: GetDeploymentUrl(id), IsInternal: false)); 333Urls = [.. state.Urls.Where(static url => !string.Equals(url.Name, DeploymentUrlName, StringComparison.Ordinal)), new(Name: DeploymentUrlName, Url: deploymentUrl, IsInternal: false)], 695Urls = [.. state.Urls, new(Name: DeploymentUrlName, Url: url, IsInternal: false)],
Aspire.Hosting.Azure.EntraId (2)
EntraIdResourceExtensions.cs (2)
230urls.Add(new UrlSnapshot("OpenID Config", EntraIdUrls.GetOpenIdConfigurationUrl(resource.Instance, signInTenant), IsInternal: false) 237urls.Add(new UrlSnapshot("Azure Portal", portalUrl, IsInternal: false)
Aspire.Hosting.Azure.EntraId.Tests (7)
EntraIdInitializationTests.cs (7)
30new("OpenID Config", $"https://login.microsoftonline.com/{TenantId}/v2.0/.well-known/openid-configuration", IsInternal: false) 34new("Azure Portal", $"https://portal.azure.com/#@{TenantId}/view/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/~/Overview/appId/{ClientId}/isMSAApp~/false", IsInternal: false) 83new("OpenID Config", "https://login.microsoftonline.com/organizations/v2.0/.well-known/openid-configuration", IsInternal: false) 87new("Azure Portal", $"https://portal.azure.com/#@{TenantId}/view/Microsoft_AAD_RegisteredApps/ApplicationMenuBlade/~/Overview/appId/{ClientId}/isMSAApp~/false", IsInternal: false) 115new("OpenID Config", $"https://login.contoso.example/{TenantId}/v2.0/.well-known/openid-configuration", IsInternal: false) 318Urls = [new("docs", "https://contoso.example/docs", IsInternal: false)], 439Urls = [new UrlSnapshot("docs", "https://contoso.example/docs", IsInternal: false)],
Aspire.Hosting.Azure.Functions (1)
DurableTask\DurableTaskResourceExtensions.cs (1)
244? [new("dashboard", url, false) { DisplayProperties = new() { DisplayName = "Task Hub Dashboard" } }]
Aspire.Hosting.Azure.Tests (4)
AzureEnvironmentResourceExtensionsTests.cs (4)
102Urls = [new("Entra registration", "https://entra.microsoft.com", IsInternal: false)] 640new("deployment", "https://portal.azure.com", false) 2419Urls = [new("deployment", "https://portal.azure.com/storage", false)], 2426Urls = [new("deployment", "https://portal.azure.com/storage2", false)],
Aspire.Hosting.Blazor (1)
BlazorGatewayExtensions.cs (1)
880builder.Add(new UrlSnapshot(
Aspire.Hosting.DevTunnels.Tests (8)
DevTunnelMonitorTests.cs (8)
185Urls = [new("tunnel", test.Port.LastKnownStatus!.PortUri!.AbsoluteUri, false)] 209Urls = [new("tunnel", "https://original-3000.usw2.devtunnels.ms/", false)] 260new("tunnel", "https://original-3000.usw2.devtunnels.ms/swagger?x=1#operations", false), 261new("tunnel", "https://original-3000.usw2.devtunnels.ms/health?next=%2F", false), 262new("tunnel", "https://docs.example/guide?x=1", false), 263new(null, "https://original-3000-inspect.usw2.devtunnels.ms/requests?id=1", true) { DisplayProperties = new("Inspect") } 318Urls = [new("tunnel", "https://original-3000.usw2.devtunnels.ms/", false)] 350Urls = [new("tunnel", "https://original-3000.usw2.devtunnels.ms/", false)]
Aspire.Hosting.Foundry (1)
PromptAgent\AzurePromptAgentResource.cs (1)
435return [new UrlSnapshot(Name: "Foundry Portal", Url: portalUrl, IsInternal: false)];
Aspire.Hosting.Tests (5)
Backchannel\AuxiliaryBackchannelRpcTargetTests.cs (3)
187new UrlSnapshot("http", "http://localhost:5000", false) { DisplayProperties = new UrlDisplayPropertiesSnapshot("HTTP Endpoint", 1) }, 188new UrlSnapshot("https", "https://localhost:5001", true) { DisplayProperties = new UrlDisplayPropertiesSnapshot("HTTPS Endpoint", 2) }, 189new UrlSnapshot("inactive", "http://localhost:5002", false) { IsInactive = true }
Codespaces\CodespacesUrlRewriterTests.cs (1)
72var localhostUrlSnapshot = new UrlSnapshot("Test", "http://localhost:1234", false);
ResourceNotificationTests.cs (1)
1797new UrlSnapshot("ep", "http://localhost:8080", IsInternal: false)
34 references to UrlSnapshot
Aspire.Hosting (14)
ApplicationModel\CustomResourceSnapshot.cs (1)
110public ImmutableArray<UrlSnapshot> Urls { get; init; } = [];
Dashboard\proto\Partials.cs (1)
55foreach (var urlSnapshot in snapshot.Urls)
Dashboard\ResourceSnapshot.cs (1)
27public required ImmutableArray<UrlSnapshot> Urls { get; init; }
Dcp\ResourceSnapshotBuilder.cs (2)
541private ImmutableArray<UrlSnapshot> GetUrls(CustomResource resource, string? resourceState) 543var urls = ImmutableArray.CreateBuilder<UrlSnapshot>();
Devcontainers\Codespaces\CodespacesResourceUrlRewriterService.cs (5)
30Dictionary<UrlSnapshot, UrlSnapshot>? remappedUrls = null; 32foreach (var originalUrlSnapshot in resourceEvent.Snapshot.Urls) 40var newUrlSnapshot = originalUrlSnapshot with 58select remappedUrls.TryGetValue(originalUrl, out var remappedUrl) ? remappedUrl : originalUrl;
ExternalServiceBuilderExtensions.cs (2)
179static ImmutableArray<UrlSnapshot> AddUrlIfNotPresent(ImmutableArray<UrlSnapshot> urlSnapshots, Uri uri)
Orchestrator\ApplicationOrchestrator.cs (2)
218private static IEnumerable<UrlSnapshot> GetResourceUrls(IResource resource) 220IEnumerable<UrlSnapshot> urls = [];
Aspire.Hosting.Azure (1)
Provisioning\Provisioners\BicepProvisioner.cs (1)
112var portalUrls = new List<UrlSnapshot>();
Aspire.Hosting.Azure.EntraId (1)
EntraIdResourceExtensions.cs (1)
229var urls = ImmutableArray.CreateBuilder<UrlSnapshot>();
Aspire.Hosting.Azure.EntraId.Tests (3)
EntraIdInitializationTests.cs (3)
28Assert.Equal(new UrlSnapshot[] 81Assert.Equal(new UrlSnapshot[] 113Assert.Equal(new UrlSnapshot[]
Aspire.Hosting.Blazor (2)
BlazorGatewayExtensions.cs (2)
874private static ImmutableArray<UrlSnapshot> BuildClientUrls( 877var builder = ImmutableArray.CreateBuilder<UrlSnapshot>(endpoints.Count);
Aspire.Hosting.DevTunnels (1)
DevTunnelResourceBuilderExtensions.cs (1)
764private static string UpdatePortUrl(UrlSnapshot url, string? previousAddress, Uri portUri)
Aspire.Hosting.Foundry (1)
PromptAgent\AzurePromptAgentResource.cs (1)
413private async Task<ImmutableArray<UrlSnapshot>> BuildPortalUrlsAsync(IConfiguration configuration, CancellationToken cancellationToken)
Aspire.Hosting.Redis.Tests (2)
RedisFunctionalTests.cs (2)
133var managementUrl = redisEvent.Snapshot.Urls.First(u => u.DisplayProperties.DisplayName == "Manage (Commander)"); 171var managementUrl = redisEvent.Snapshot.Urls.FirstOrDefault(u => u.DisplayProperties.DisplayName == "Manage (Commander)");
Aspire.Hosting.Tests (9)
Codespaces\CodespacesUrlRewriterTests.cs (1)
72var localhostUrlSnapshot = new UrlSnapshot("Test", "http://localhost:1234", false);
WithUrlsTests.cs (8)
111var urlSnapshots = new List<UrlSnapshot[]>(); 113static string FormatUrls(IEnumerable<UrlSnapshot> urls) => 158var initUrl = Assert.Single(initialized); 700var urlSnapshots = new List<UrlSnapshot[]>(); 702static string FormatUrls(IEnumerable<UrlSnapshot> urls) => 747var initUrl = Assert.Single(initialized); 1133var crossResourceUrl = resourceEvent.Snapshot.Urls.FirstOrDefault(u => u.DisplayProperties.DisplayName == "API Docs"); 1174var crossResourceUrl = resourceEvent.Snapshot.Urls.FirstOrDefault(u => u.DisplayProperties.DisplayName == "API Docs");