33 references to KnownResourceCommands
Aspire.Hosting (13)
ApplicationModel\CommandsConfigurationExtensions.cs (4)
23name: KnownResourceCommands.StartCommand, 56name: KnownResourceCommands.StopCommand, 95name: KnownResourceCommands.RestartCommand, 153name: KnownResourceCommands.RebuildCommand,
ApplicationModel\ResourceCommandService.cs (6)
18[KnownResourceCommands.LegacyStartCommand] = KnownResourceCommands.StartCommand, 19[KnownResourceCommands.LegacyStopCommand] = KnownResourceCommands.StopCommand, 20[KnownResourceCommands.LegacyRestartCommand] = KnownResourceCommands.RestartCommand,
Orchestrator\ParameterProcessor.cs (3)
147if (executionContext.IsRunMode && interactionService.IsAvailable && !parameterResource.Annotations.OfType<ResourceCommandAnnotation>().Any(a => a.Name == KnownResourceCommands.SetParameterCommand)) 198name: KnownResourceCommands.SetParameterCommand, 214name: KnownResourceCommands.DeleteParameterCommand,
Aspire.Hosting.Tests (18)
Dcp\DcpExecutorTests.cs (7)
2330a => Assert.Equal(KnownResourceCommands.StartCommand, a.Name), 2331a => Assert.Equal(KnownResourceCommands.StopCommand, a.Name), 2332a => Assert.Equal(KnownResourceCommands.RestartCommand, a.Name)); 2339a => Assert.Equal(KnownResourceCommands.StartCommand, a.Name), 2340a => Assert.Equal(KnownResourceCommands.StopCommand, a.Name), 2341a => Assert.Equal(KnownResourceCommands.RestartCommand, a.Name), 2342a => Assert.Equal(KnownResourceCommands.RebuildCommand, a.Name));
Eventing\DistributedApplicationBuilderEventingTests.cs (1)
333await app.ResourceCommands.ExecuteCommandAsync("redis", KnownResourceCommands.StopCommand);
Orchestrator\ParameterProcessorTests.cs (2)
865.SingleOrDefault(a => a.Name == KnownResourceCommands.SetParameterCommand); 885.SingleOrDefault(a => a.Name == KnownResourceCommands.SetParameterCommand);
ResourceCommandAnnotationTests.cs (6)
83var restartCommand = resourceBuilder.Resource.Annotations.OfType<ResourceCommandAnnotation>().Single(a => a.Name == KnownResourceCommands.RestartCommand); 98var restartCommand = projectResource.Annotations.OfType<ResourceCommandAnnotation>().Single(a => a.Name == KnownResourceCommands.RestartCommand); 113var restartCommand = csharpAppResource.Annotations.OfType<ResourceCommandAnnotation>().Single(a => a.Name == KnownResourceCommands.RestartCommand); 164Assert.DoesNotContain(containerResource.Resource.Annotations.OfType<ResourceCommandAnnotation>(), a => a.Name == KnownResourceCommands.RebuildCommand); 165Assert.Contains(projectResource.Annotations.OfType<ResourceCommandAnnotation>(), a => a.Name == KnownResourceCommands.RebuildCommand); 174var rebuildCommand = projectResource.Annotations.OfType<ResourceCommandAnnotation>().Single(a => a.Name == KnownResourceCommands.RebuildCommand);
ResourceCommandServiceTests.cs (2)
336custom.WithCommand(name: KnownResourceCommands.StartCommand, 357custom.WithCommand(name: KnownResourceCommands.StopCommand,
Stress.AppHost (2)
Program.cs (2)
115await ExecuteCommandForAllResourcesAsync(c.ServiceProvider, KnownResourceCommands.StopCommand, c.CancellationToken); 124await ExecuteCommandForAllResourcesAsync(c.ServiceProvider, KnownResourceCommands.StartCommand, c.CancellationToken);