30 instantiations of DeploymentStateSection
Aspire.Hosting (1)
Pipelines\Internal\DeploymentStateManagerBase.cs (1)
203
var section = new
DeploymentStateSection
(sectionName, data, metadata.Version);
Aspire.Hosting.Azure.Kubernetes.Tests (2)
tests\Shared\InMemoryDeploymentStateManager.cs (2)
32
return Task.FromResult(new
DeploymentStateSection
(sectionName, data, version));
34
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
Aspire.Hosting.Azure.Sandboxes (4)
AzureSandboxContainerDeployment.cs (4)
451
new
DeploymentStateSection
(
1378
new
DeploymentStateSection
(stateSection.SectionName, pendingLegacyDeploymentCleanup, version: 0),
1449
new
DeploymentStateSection
(sectionName, pendingLegacyDeploymentCleanup, version: 0),
1632
return new
DeploymentStateSection
(
Aspire.Hosting.Azure.Tests (14)
AzureBicepProvisionerTests.cs (1)
1950
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
AzureDeployerTests.cs (1)
1534
=> Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
AzureEnvironmentResourceExtensionsTests.cs (1)
5383
return Task.FromResult(new
DeploymentStateSection
(sectionName, data, version: 0));
AzureSandboxesTests.cs (8)
787
var ownerOnlyState = new
DeploymentStateSection
(
791
var emptyState = new
DeploymentStateSection
(
803
var state = new
DeploymentStateSection
(
869
var state = new
DeploymentStateSection
(
905
var state = new
DeploymentStateSection
(
972
var previousState = new
DeploymentStateSection
(
1091
var state = new
DeploymentStateSection
("sandbox", new JsonObject
1129
var state = new
DeploymentStateSection
("sandbox", new JsonObject
ProvisioningTestHelpers.cs (1)
1043
return Task.FromResult(new
DeploymentStateSection
(sectionName, sectionData, 0));
tests\Shared\InMemoryDeploymentStateManager.cs (2)
32
return Task.FromResult(new
DeploymentStateSection
(sectionName, data, version));
34
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
Aspire.Hosting.Docker.Tests (2)
tests\Shared\InMemoryDeploymentStateManager.cs (2)
32
return Task.FromResult(new
DeploymentStateSection
(sectionName, data, version));
34
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
Aspire.Hosting.Kubernetes.Tests (2)
tests\Shared\InMemoryDeploymentStateManager.cs (2)
32
return Task.FromResult(new
DeploymentStateSection
(sectionName, data, version));
34
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
Aspire.Hosting.Tests (5)
Orchestrator\ApplicationOrchestratorTests.cs (1)
1170
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
Orchestrator\ParameterProcessorTests.cs (2)
1306
return Task.FromResult(new
DeploymentStateSection
(sectionName, [], 0));
1668
return Task.FromResult(new
DeploymentStateSection
(sectionName, sectionData, 0));
Publishing\DeploymentStateManagerTests.cs (2)
83
oldSection = new
DeploymentStateSection
(section1.SectionName, section1.Data, oldVersion);
329
var oldSection = new
DeploymentStateSection
(section1.SectionName, section1.Data, oldVersion);
384 references to DeploymentStateSection
Aspire.Hosting (19)
Orchestrator\ParameterProcessor.cs (7)
254
var
parameterSection = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, context.CancellationToken).ConfigureAwait(false);
294
var
parameterSection = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, context.CancellationToken).ConfigureAwait(false);
349
var
parameterSection = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, cancellationToken).ConfigureAwait(false);
379
var
parameterSection = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, cancellationToken).ConfigureAwait(false);
456
var
parameterSection = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, cancellationToken).ConfigureAwait(false);
521
var
slot = await deploymentStateManager.AcquireSectionAsync(parameterResource.ConfigurationKey, cancellationToken).ConfigureAwait(false);
683
var
slot = await deploymentStateManager.AcquireSectionAsync(parameter.ConfigurationKey, cancellationToken).ConfigureAwait(false);
Pipelines\DeploymentStateSection.cs (1)
13
/// Initializes a new instance of the <see cref="
DeploymentStateSection
"/> class.
Pipelines\IDeploymentStateManager.cs (4)
26
Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default);
38
Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
48
Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default);
57
Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default);
Pipelines\Internal\DeploymentStateManagerBase.cs (7)
172
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default) =>
176
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default) =>
179
private async Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, bool includeLegacyState, CancellationToken cancellationToken)
203
var
section = new DeploymentStateSection(sectionName, data, metadata.Version);
247
public async Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
268
public async Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
288
private async Task EnsureStateAndSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken)
Aspire.Hosting.Azure (39)
AzureEnvironmentResource.cs (1)
230
var
azureStateSection = await deploymentStateManager.AcquireSectionAsync("Azure", context.CancellationToken).ConfigureAwait(false);
AzureProvisioningController.cs (18)
1213
var
section = await deploymentStateManager.AcquireSectionAsync(sectionName, cancellationToken).ConfigureAwait(false);
1856
var
section = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
2509
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
2744
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{bicepResource.Name}", cancellationToken).ConfigureAwait(false);
2763
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resourceName}", cancellationToken).ConfigureAwait(false);
2776
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resourceName}", cancellationToken).ConfigureAwait(false);
2802
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{bicepResource.Name}", cancellationToken).ConfigureAwait(false);
2839
var
section = await deploymentStateManager.AcquireSectionAsync(sectionName, cancellationToken).ConfigureAwait(false);
2923
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
3091
private static string? TryGetCachedDeploymentId(
DeploymentStateSection
section)
3094
private static bool IsActiveCachedDeployment(
DeploymentStateSection
section)
3148
private string? TryGetPreservedLocationOverride(AzureBicepResource resource,
DeploymentStateSection
section, string? environmentLocation)
3187
private static string? TryGetExplicitLocationOverride(
DeploymentStateSection
section)
3366
var
section = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
3392
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
3511
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
3581
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
3813
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{bicepResource.Name}").ConfigureAwait(false);
Provisioning\BicepUtilities.cs (1)
169
public static async ValueTask<string?> GetCurrentChecksumAsync(AzureBicepResource resource,
DeploymentStateSection
section, ILogger logger, CancellationToken cancellationToken = default)
Provisioning\Internal\BaseProvisioningContextProvider.cs (3)
115
var
azureStateSection = await _deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
207
var
azureStateSection = await _deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
215
DeploymentStateSection
azureStateSection,
Provisioning\Internal\RunModeProvisioningContextProvider.cs (1)
227
var
azureSection = await _deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
Provisioning\Provisioners\BicepProvisioner.cs (15)
54
var
stateSection = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
176
var
stateSection = await deploymentStateManager.AcquireSectionAsync(sectionName, cancellationToken).ConfigureAwait(false);
351
DeploymentStateSection
stateSection,
394
DeploymentStateSection
stateSection,
439
private async Task PersistReconciledProvisioningStateAsync(
DeploymentStateSection
stateSection, string provisioningState, CancellationToken cancellationToken)
453
private async Task ClearCachedRunningDeploymentStateAsync(
DeploymentStateSection
stateSection, CancellationToken cancellationToken)
470
DeploymentStateSection
stateSection,
493
private static bool IsRunningCachedDeployment(
DeploymentStateSection
stateSection)
621
var
canceledStateSection = await deploymentStateManager.AcquireSectionAsync(sectionName, CancellationToken.None).ConfigureAwait(false);
672
DeploymentStateSection
? stateSection = null;
854
var
stateSection = await deploymentStateManager.AcquireSectionAsync(sectionName, cancellationToken).ConfigureAwait(false);
1316
DeploymentStateSection
stateSection,
1476
var
section = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
1486
private static string? GetStateValue(
DeploymentStateSection
section, string key) =>
1489
private static string GetConfiguredLocation(
DeploymentStateSection
section, string? fallbackLocation)
Aspire.Hosting.Azure.Kubernetes (5)
AzureKubernetesEnvironmentResource.AksPipeline.cs (2)
367
var
deploymentStateSection = await deploymentStateManager
779
var
azureState = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken).ConfigureAwait(false);
AzureKubernetesEnvironmentResource.cs (3)
101
var
deploymentStateSection = await deploymentStateManager
170
var
environmentState = await deploymentStateManager
186
var
chartState = await deploymentStateManager
Aspire.Hosting.Azure.Kubernetes.Tests (5)
AzureKubernetesInfrastructureTests.cs (2)
338
var
chartStateAfterFirstDestroy = await stateManager.AcquireSectionAsync(
700
var
sentinelState = await stateManager.AcquireSectionAsync(
tests\Shared\InMemoryDeploymentStateManager.cs (3)
27
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
37
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
44
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Aspire.Hosting.Azure.Sandboxes (25)
AzureSandboxContainerDeployment.cs (23)
259
var
stateSection = await deploymentStateManager.AcquireSectionAsync(GetStateSectionName(resource), context.CancellationToken).ConfigureAwait(false);
261
var
previousStateSection = CloneStateSection(stateSection);
1321
var
stateSection = await deploymentStateManager.AcquireSectionAsync(GetStateSectionName(resource), context.CancellationToken).ConfigureAwait(false);
1399
var
sandboxesSection = await deploymentStateManager.AcquireCurrentSectionAsync(SandboxStateParentSection, context.CancellationToken).ConfigureAwait(false);
1415
var
stateSection = await deploymentStateManager.AcquireSectionAsync(sectionName, context.CancellationToken).ConfigureAwait(false);
1590
DeploymentStateSection
stateSection,
1630
private static
DeploymentStateSection
CloneStateSection(
DeploymentStateSection
stateSection)
1870
private static string GetStateResourceName(
DeploymentStateSection
stateSection, string sectionName)
1928
DeploymentStateSection
stateSection,
1947
DeploymentStateSection
stateSection,
1964
DeploymentStateSection
stateSection,
1981
private static JsonObject? GetPendingLegacyDeploymentCleanup(
DeploymentStateSection
stateSection) =>
1985
DeploymentStateSection
stateSection,
2058
DeploymentStateSection
previousStateSection,
2094
DeploymentStateSection
stateSection,
2106
internal static void ValidateDeploymentScope(
DeploymentStateSection
stateSection, AzureDevComputeResourceScope scope)
2136
internal static bool HasRemoteDeploymentState(
DeploymentStateSection
stateSection) =>
2152
private static string? GetFirstStateUrl(
DeploymentStateSection
stateSection)
2170
private static IReadOnlySet<string> GetExcludedDeployIds(string deployId,
DeploymentStateSection
previousStateSection)
2185
private static IReadOnlySet<string> GetExcludedResourceIds(string id,
DeploymentStateSection
previousStateSection, string stateKey)
2200
private static IEnumerable<int> GetStatePorts(
DeploymentStateSection
stateSection)
2302
private static string GetRequiredStateValue(
DeploymentStateSection
section, string name)
AzureSandboxEndpointPropertyValueProvider.cs (2)
66
var
stateSection = await deploymentStateManager
120
private bool TryGetUrl(
DeploymentStateSection
stateSection, [NotNullWhen(true)] out string? url)
Aspire.Hosting.Azure.Tests (131)
AzureBicepProvisionerTests.cs (26)
836
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
870
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
906
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure", CancellationToken.None);
914
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
957
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure", CancellationToken.None);
965
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
999
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1033
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1082
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1337
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1370
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1402
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1436
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1495
var
section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2", CancellationToken.None);
1596
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1651
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1677
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1706
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1732
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1757
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1790
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1848
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}");
1948
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1953
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1956
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1961
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
AzureDeployerTests.cs (4)
1533
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1536
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1539
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default) => Task.CompletedTask;
1541
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default) => Task.CompletedTask;
AzureEnvironmentResourceExtensionsTests.cs (76)
318
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
323
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
589
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
625
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
789
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
796
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
901
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1176
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1234
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1295
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1357
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1485
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1661
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1699
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1766
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
1780
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
1869
var
keyVaultSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:kv");
1941
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2020
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2087
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2091
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
2165
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2169
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
2803
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2850
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2908
var
bicepSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage-deployment");
2911
var
visibleSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
2937
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
2943
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3009
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3076
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3135
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3201
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3265
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3330
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3383
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3390
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3394
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
3461
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3508
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3557
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3603
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3609
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3663
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3669
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
3704
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3710
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
3749
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
3782
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
3809
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
3911
var
keyVaultSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:kv3");
3991
var
keyVaultSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:kv3");
4315
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4323
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4364
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4370
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4412
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4418
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4428
var
storage2Section = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage2");
4472
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4478
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4511
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4518
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4570
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4611
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4617
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4659
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure");
4665
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
4796
var
storageSection = await deploymentStateManager.AcquireSectionAsync("Azure:Deployments:storage");
5374
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
5386
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
5389
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
5399
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
5553
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken);
5565
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure", cancellationToken);
5698
var
section = await deploymentStateManager.AcquireSectionAsync($"Azure:Deployments:{resource.Name}", cancellationToken).ConfigureAwait(false);
AzureSandboxesTests.cs (15)
787
var
ownerOnlyState = new DeploymentStateSection(
791
var
emptyState = new DeploymentStateSection(
803
var
state = new DeploymentStateSection(
869
var
state = new DeploymentStateSection(
905
var
state = new DeploymentStateSection(
972
var
previousState = new DeploymentStateSection(
1091
var
state = new DeploymentStateSection("sandbox", new JsonObject
1129
var
state = new DeploymentStateSection("sandbox", new JsonObject
1153
var
azureState = await stateManager.AcquireSectionAsync("Azure", TestContext.Current.CancellationToken);
2727
var
state = await stateManager.AcquireSectionAsync(
2860
var
state = await stateManager.AcquireSectionAsync(
3146
var
state = await stateManager.AcquireSectionAsync(
3554
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default) => throw new NotSupportedException();
3555
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default) => throw new NotSupportedException();
3556
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default) => throw new NotSupportedException();
ProvisioningContextProviderTests.cs (1)
136
var
azureSection = await deploymentStateManager.AcquireSectionAsync("Azure", CancellationToken.None);
ProvisioningContextTests.cs (2)
202
var
azureSection = await manager.AcquireSectionAsync("Azure");
206
var
loadedSection = await manager.AcquireSectionAsync("Azure");
ProvisioningTestHelpers.cs (4)
1038
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1046
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1049
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1054
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
tests\Shared\InMemoryDeploymentStateManager.cs (3)
27
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
37
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
44
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Aspire.Hosting.Docker (2)
DockerComposeEnvironmentResource.cs (2)
146
var
stateSection = await deploymentStateManager.AcquireSectionAsync($"DockerCompose:{Name}", ctx.CancellationToken).ConfigureAwait(false);
454
var
stateSection = await deploymentStateManager.AcquireSectionAsync($"DockerCompose:{Name}", context.CancellationToken).ConfigureAwait(false);
Aspire.Hosting.Docker.Tests (4)
DockerComposeTests.cs (1)
1055
var
stateSection = await stateManager.AcquireSectionAsync("DockerCompose:env");
tests\Shared\InMemoryDeploymentStateManager.cs (3)
27
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
37
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
44
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Aspire.Hosting.Kubernetes (4)
Deployment\HelmDeploymentEngine.cs (2)
203
var
stateSection = await deploymentStateManager.AcquireSectionAsync($"Helm:{environment.Name}", ctx.CancellationToken).ConfigureAwait(false);
491
var
stateSection = await deploymentStateManager.AcquireSectionAsync($"Helm:{environment.Name}", context.CancellationToken).ConfigureAwait(false);
KubernetesHelmChartExtensions.cs (2)
370
var
stateSection = await deploymentStateManager
402
var
stateSection = await deploymentStateManager
Aspire.Hosting.Kubernetes.Tests (6)
KubernetesDeployTests.cs (3)
1994
var
stateSection = await stateManager.AcquireSectionAsync("Helm:env");
2040
var
stateSection = await stateManager.AcquireSectionAsync("Helm:env");
2093
var
stateSection = await stateManager.AcquireSectionAsync("HelmChart:env:podinfo");
tests\Shared\InMemoryDeploymentStateManager.cs (3)
27
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
37
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
44
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Aspire.Hosting.Tests (144)
Orchestrator\ApplicationOrchestratorTests.cs (4)
1168
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1173
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1176
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1183
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Orchestrator\ParameterProcessorTests.cs (12)
974
var
section = await deploymentStateManager.AcquireSectionAsync(parameter.ConfigurationKey).DefaultTimeout();
1045
var
section = await deploymentStateManager.AcquireSectionAsync(parameter.ConfigurationKey).DefaultTimeout();
1304
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1309
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1312
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1319
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1533
var
section = await capturingStateManager.AcquireSectionAsync($"Parameters:{parameter.Name}").DefaultTimeout();
1634
var
section = await capturingStateManager.AcquireSectionAsync($"Parameters:{parameter.Name}").DefaultTimeout();
1661
public Task<
DeploymentStateSection
> AcquireSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1671
public Task<
DeploymentStateSection
> AcquireCurrentSectionAsync(string sectionName, CancellationToken cancellationToken = default)
1674
public Task SaveSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
1690
public Task DeleteSectionAsync(
DeploymentStateSection
section, CancellationToken cancellationToken = default)
Publishing\DeploymentStateManagerTests.cs (128)
28
var
section = await stateManager.AcquireSectionAsync("Parameters");
42
var
section1 = await stateManager.AcquireSectionAsync("Parameters");
48
var
section2 = await stateManager.AcquireSectionAsync("Parameters");
59
var
section = await stateManager.AcquireSectionAsync("Parameters");
65
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Parameters");
76
DeploymentStateSection
oldSection;
77
var
section1 = await stateManager.AcquireSectionAsync("Parameters");
87
var
section2 = await stateManager.AcquireSectionAsync("Parameters");
105
var
parametersSection = await stateManager.AcquireSectionAsync("Parameters");
106
var
azureSection = await stateManager.AcquireSectionAsync("Azure");
115
var
parametersCheck = await stateManager.AcquireSectionAsync("Parameters");
116
var
azureCheck = await stateManager.AcquireSectionAsync("Azure");
136
var
section = await stateManager.AcquireSectionAsync($"Section{sectionIndex}");
148
var
section = await verifyManager.AcquireSectionAsync($"Section{i}");
158
var
section1 = await stateManager.AcquireSectionAsync("Parameters");
164
var
section2 = await stateManager.AcquireSectionAsync("Parameters");
165
var
section3 = await stateManager.AcquireSectionAsync("Azure");
179
var
section1 = await stateManager.AcquireSectionAsync("Parameters");
186
var
section2 = await stateManager2.AcquireSectionAsync("Parameters");
199
var
section3 = await stateManager3.AcquireSectionAsync("Parameters");
216
var
section2 = await stateManager.AcquireSectionAsync("Parameters");
235
var
parametersSection = await stateManager.AcquireSectionAsync("Parameters");
236
var
azureSection = await stateManager.AcquireSectionAsync("Azure");
238
var
restartedParametersSection = await restartedStateManager.AcquireSectionAsync("Parameters");
252
var
section = await stateManager.AcquireSectionAsync("TestParent:TestChild:TestGrandchild");
257
var
retrievedSection = await stateManager.AcquireSectionAsync("TestParent:TestChild:TestGrandchild");
269
var
section = await stateManager.AcquireSectionAsync("Parent:Child:Grandchild");
275
var
verifySection = await verifyManager.AcquireSectionAsync("Parent:Child:Grandchild");
285
var
section1 = await stateManager.AcquireSectionAsync("Root:Branch1:Leaf");
286
var
section2 = await stateManager.AcquireSectionAsync("Root:Branch2:Leaf");
294
var
verify1 = await stateManager.AcquireSectionAsync("Root:Branch1:Leaf");
295
var
verify2 = await stateManager.AcquireSectionAsync("Root:Branch2:Leaf");
306
var
section = await stateManager.AcquireSectionAsync("Root:Branch1:Leaf");
312
var
verify = await stateManager.AcquireSectionAsync("Root:Branch1:Leaf");
323
var
section1 = await stateManager.AcquireSectionAsync("Parent:Child:Grandchild");
329
var
oldSection = new DeploymentStateSection(section1.SectionName, section1.Data, oldVersion);
332
var
section2 = await stateManager.AcquireSectionAsync("Parent:Child:Grandchild");
348
var
section = await stateManager.AcquireSectionAsync("Nonexistent:Path:Here");
362
var
topLevel = await stateManager.AcquireSectionAsync("TopLevel");
363
var
nested = await stateManager.AcquireSectionAsync("Parent:Child");
371
var
verifyTop = await stateManager.AcquireSectionAsync("TopLevel");
372
var
verifyNested = await stateManager.AcquireSectionAsync("Parent:Child");
384
var
section = await stateManager.AcquireSectionAsync("PermTest");
475
var
legacySection = await legacyStateManager.AcquireSectionAsync("Migration");
480
var
migratedSection = await migratingStateManager.AcquireSectionAsync("Migration");
492
var
currentSection = await currentStateManager.AcquireSectionAsync("Migration");
512
var
legacySection = await legacyStateManager.AcquireSectionAsync("Legacy");
516
var
migratedSection = await migratingStateManager.AcquireSectionAsync("Legacy");
528
var
sameManagerLegacySection = await migratingStateManager.AcquireSectionAsync("Legacy");
533
var
legacyAfterRestart = await restartedStateManager.AcquireSectionAsync("Legacy");
534
var
replacementAfterRestart = await restartedStateManager.AcquireSectionAsync("Replacement");
551
var
section = await stateManager.AcquireSectionAsync("Parameters");
558
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Parameters");
568
var
legacySection = await legacyStateManager.AcquireSectionAsync("Parameters");
573
var
section = await stateManager.AcquireSectionAsync("Parameters");
596
var
parameterSection = await migratingStateManager.AcquireSectionAsync("Parameters:secret");
623
var
section = await stateManager.AcquireSectionAsync("Parameters:secret");
629
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Parameters:secret");
646
var
initialSection = await initialStateManager.AcquireSectionAsync("Parameters:secret");
652
var
staleSection = await staleStateManager.AcquireSectionAsync("Parameters:secret");
653
var
updatingSection = await updatingStateManager.AcquireSectionAsync("Parameters:secret");
660
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Parameters:secret");
677
var
initialSection = await initialStateManager.AcquireSectionAsync("Settings");
683
var
staleObjectSection = await staleObjectManager.AcquireSectionAsync("Settings");
684
var
scalarSection = await scalarManager.AcquireSectionAsync("Settings");
692
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Settings");
711
var
firstSection = await firstStateManager.AcquireSectionAsync("Settings");
712
var
secondSection = await secondStateManager.AcquireSectionAsync("Settings");
720
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Settings");
739
var
firstLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
742
var
secondLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
747
var
currentParentSection = await firstStateManager.AcquireCurrentSectionAsync("Azure:Sandboxes");
750
var
firstSection = await firstStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
755
var
migratedFirstSection = await firstCanonicalStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
756
var
inheritedSecondSection = await firstCanonicalStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
761
var
migratedParentSection = await firstStateManager.AcquireSectionAsync("Azure:Sandboxes");
763
var
migratedCurrentParentSection = await firstStateManager.AcquireCurrentSectionAsync("Azure:Sandboxes");
767
var
restartedFirstSection = await restartedFirstStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
768
var
restartedSecondSection = await restartedFirstStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
769
var
restartedCurrentParentSection = await restartedFirstStateManager.AcquireCurrentSectionAsync("Azure:Sandboxes");
775
var
secondSection = await secondStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
784
var
clearedFirstLegacySection = await legacyAfterClearManager.AcquireSectionAsync("Azure:Sandboxes:first");
785
var
preservedSecondLegacySection = await legacyAfterClearManager.AcquireSectionAsync("Azure:Sandboxes:second");
796
var
legacyAzureSection = await legacyStateManager.AcquireSectionAsync("Azure");
806
var
azureSection = await migratingStateManager.AcquireSectionAsync("Azure");
810
var
currentAzureSection = await migratingStateManager.AcquireCurrentSectionAsync("Azure");
815
var
restartedAzureSection = await restartedStateManager.AcquireSectionAsync("Azure");
832
var
legacyAzureSection = await legacyStateManager.AcquireSectionAsync("Azure");
840
var
azureSection = await migratingStateManager.AcquireSectionAsync("Azure");
843
var
newSandboxSection = await migratingStateManager.AcquireSectionAsync("Azure:Sandboxes:new");
848
var
restartedAzureSection = await restartedStateManager.AcquireSectionAsync("Azure");
873
var
legacySandboxesSection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes");
885
var
firstSandboxSection = await migratingStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
888
var
newChildSection = await migratingStateManager.AcquireSectionAsync("Azure:Sandboxes:first:new");
893
var
restartedSandboxesSection = await restartedStateManager.AcquireSectionAsync("Azure:Sandboxes");
917
var
firstLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
920
var
secondLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
926
var
firstSection = await firstStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
927
var
secondSection = await secondStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
936
var
restartedFirstSection = await restartedStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
937
var
restartedSecondSection = await restartedStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
943
var
currentParentSection = await restartedStateManager.AcquireCurrentSectionAsync("Azure:Sandboxes");
953
var
legacyAzureSection = await legacyStateManager.AcquireSectionAsync("Azure");
960
var
firstAzureSection = await firstStateManager.AcquireSectionAsync("Azure");
961
var
secondAzureSection = await secondStateManager.AcquireSectionAsync("Azure");
970
var
restartedAzureSection = await restartedStateManager.AcquireSectionAsync("Azure");
974
var
currentAzureSection = await restartedStateManager.AcquireCurrentSectionAsync("Azure");
985
var
legacySection = await legacyStateManager.AcquireSectionAsync("Azure");
1002
var
suppressedLegacySection = await restartedCurrentStateManager.AcquireSectionAsync("Azure");
1005
var
preservedLegacySection = await preservedLegacyStateManager.AcquireSectionAsync("Azure");
1015
var
currentSection = await currentStateManager.AcquireSectionAsync("Azure");
1034
var
migratedSection = await migratingStateManager.AcquireSectionAsync("Azure");
1046
var
currentSection = await currentStateManager.AcquireSectionAsync("Azure");
1058
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Azure");
1066
var
savedSection = await CreateFileDeploymentStateManager(currentSha).AcquireSectionAsync("Azure");
1076
var
section = await stateManager.AcquireSectionAsync("Azure");
1086
var
currentSection = await stateManager.AcquireCurrentSectionAsync("Azure");
1096
var
legacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:frontend");
1101
var
migratedSection = await migratingStateManager.AcquireSectionAsync("Azure:Sandboxes:frontend");
1106
var
restartedSection = await restartedStateManager.AcquireSectionAsync("Azure:Sandboxes:frontend");
1117
var
firstLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
1120
var
secondLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
1125
var
firstSection = await migratingStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
1129
var
azureSection = await parentSavingStateManager.AcquireSectionAsync("Azure");
1152
var
firstLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
1155
var
secondLegacySection = await legacyStateManager.AcquireSectionAsync("Azure:Sandboxes:second");
1161
var
firstSection = await firstStateManager.AcquireSectionAsync("Azure:Sandboxes:first");
1162
var
secondSection = await secondStateManager.AcquireSectionAsync("Azure:Sandboxes:second");