591 references to DistributedApplicationModel
Aspire.Hosting (69)
ApplicationModel\AfterEndpointsAllocatedEvent.cs (7)
12/// <param name="model">The <see cref="DistributedApplicationModel"/> instance.</param> 14/// Subscribing to this event is analogous to implementing the <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.AfterEndpointsAllocatedAsync(DistributedApplicationModel, CancellationToken)"/> 16/// <see cref="DistributedApplicationModel"/> service which is passed in as an argument 17/// in <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.AfterEndpointsAllocatedAsync(Aspire.Hosting.ApplicationModel.DistributedApplicationModel, CancellationToken)"/>. 29public class AfterEndpointsAllocatedEvent(IServiceProvider services, DistributedApplicationModel model) : IDistributedApplicationEvent 37/// The <see cref="DistributedApplicationModel"/> instance. 39public DistributedApplicationModel Model { get; } = model;
ApplicationModel\AfterResourcesCreatedEvent.cs (7)
12/// <param name="model">The <see cref="DistributedApplicationModel"/> instance.</param> 14/// Subscribing to this event is analogous to implementing the <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.AfterResourcesCreatedAsync(DistributedApplicationModel, CancellationToken)"/> 16/// <see cref="DistributedApplicationModel"/> service which is passed in as an argument 17/// in <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.AfterResourcesCreatedAsync(Aspire.Hosting.ApplicationModel.DistributedApplicationModel, CancellationToken)"/>. 29public class AfterResourcesCreatedEvent(IServiceProvider services, DistributedApplicationModel model) : IDistributedApplicationEvent 37/// The <see cref="DistributedApplicationModel"/> instance. 39public DistributedApplicationModel Model { get; } = model;
ApplicationModel\BeforeStartEvent.cs (7)
12/// <param name="model">The <see cref="DistributedApplicationModel"/> instance.</param> 14/// Subscribing to this event is analogous to implementing the <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.BeforeStartAsync(Aspire.Hosting.ApplicationModel.DistributedApplicationModel, CancellationToken)"/> 16/// <see cref="DistributedApplicationModel"/> service which is passed in as an argument 17/// in <see cref="Aspire.Hosting.Lifecycle.IDistributedApplicationLifecycleHook.BeforeStartAsync(Aspire.Hosting.ApplicationModel.DistributedApplicationModel, CancellationToken)"/>. 29public class BeforeStartEvent(IServiceProvider services, DistributedApplicationModel model) : IDistributedApplicationEvent 37/// The <see cref="DistributedApplicationModel"/> instance. 39public DistributedApplicationModel Model { get; } = model;
ApplicationModel\DistributedApplicationModel.cs (1)
16/// Initializes a new instance of the <see cref="DistributedApplicationModel"/> class with the specified resource collection.
ApplicationModel\ProjectResourceExtensions.cs (2)
7/// Provides extension methods for <see cref="DistributedApplicationModel"/> to work with <see cref="ProjectResource"/> instances. 16public static IEnumerable<ProjectResource> GetProjectResources(this DistributedApplicationModel model)
ContainerResourceExtensions.cs (1)
18public static IEnumerable<IResource> GetContainerResources(this DistributedApplicationModel model)
Dashboard\DashboardLifecycleHook.cs (5)
50public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken) 99private void AddDashboardResource(DistributedApplicationModel model) 230var model = context.ExecutionContext.ServiceProvider.GetRequiredService<DistributedApplicationModel>(); 322private static string? GetAllowedOriginsFromResourceEndpoints(DistributedApplicationModel model)
Dashboard\DashboardServiceHost.cs (1)
50DistributedApplicationModel applicationModel,
Dcp\DcpExecutor.cs (2)
48private readonly DistributedApplicationModel _model; 75DistributedApplicationModel model,
Dcp\DcpHost.cs (2)
22private readonly DistributedApplicationModel _applicationModel; 45DistributedApplicationModel applicationModel)
Devcontainers\DevcontainerPortForwardingLifecycleHook.cs (1)
27public async Task AfterEndpointsAllocatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken)
DistributedApplication.cs (3)
453var beforeStartEvent = new BeforeStartEvent(_host.Services, _host.Services.GetRequiredService<DistributedApplicationModel>()); 458var appModel = _host.Services.GetRequiredService<DistributedApplicationModel>();
DistributedApplicationBuilder.cs (2)
417var appModel = sp.GetRequiredService<DistributedApplicationModel>();
DistributedApplicationRunner.cs (1)
16internal sealed class DistributedApplicationRunner(ILogger<DistributedApplicationRunner> logger, IHostApplicationLifetime lifetime, DistributedApplicationExecutionContext executionContext, DistributedApplicationModel model, IServiceProvider serviceProvider, IPublishingActivityProgressReporter activityReporter, IDistributedApplicationEventing eventing, BackchannelService backchannelService) : BackgroundService
ExecutableResourceExtensions.cs (1)
18public static IEnumerable<ExecutableResource> GetExecutableResources(this DistributedApplicationModel model)
Lifecycle\IDistributedApplicationLifecycleHook.cs (4)
19Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default) 30Task AfterEndpointsAllocatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default) 41/// <param name="appModel">The <see cref="DistributedApplicationModel"/> for the distributed application.</param> 44Task AfterResourcesCreatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
Orchestrator\ApplicationOrchestrator.cs (2)
19private readonly DistributedApplicationModel _model; 29public ApplicationOrchestrator(DistributedApplicationModel model,
Orchestrator\RelationshipEvaluator.cs (2)
13public static ILookup<IResource, IResource> GetParentChildLookup(DistributedApplicationModel model) 24private static IEnumerable<(IResource Child, IResource Parent)> GetParentChildRelationshipsFromAnnotations(DistributedApplicationModel model)
Publishing\AfterPublishEvent.cs (4)
13/// <param name="model">The <see cref="DistributedApplicationModel"/>.</param> 14public sealed class AfterPublishEvent(IServiceProvider services, DistributedApplicationModel model) : IDistributedApplicationEvent 22/// The <see cref="DistributedApplicationModel"/> instance. 24public DistributedApplicationModel Model { get; } = model;
Publishing\BeforePublishEvent.cs (4)
13/// <param name="model">The <see cref="DistributedApplicationModel"/>.</param> 14public sealed class BeforePublishEvent(IServiceProvider services, DistributedApplicationModel model) : IDistributedApplicationEvent 22/// The <see cref="DistributedApplicationModel"/> instance. 24public DistributedApplicationModel Model { get; } = model;
Publishing\IDistributedApplicationPublisher.cs (1)
19public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken);
Publishing\ManifestPublisher.cs (3)
21public async Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken) 26protected virtual async Task PublishInternalAsync(DistributedApplicationModel model, CancellationToken cancellationToken) 61protected async Task WriteManifestAsync(DistributedApplicationModel model, Utf8JsonWriter jsonWriter, CancellationToken cancellationToken)
Publishing\ManifestPublishingContext.cs (2)
71internal async Task WriteModel(DistributedApplicationModel model, CancellationToken cancellationToken) 653private async Task WriteReferencedResources(DistributedApplicationModel model)
Publishing\Publisher.cs (1)
16public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
Publishing\PublishingContext.cs (3)
18DistributedApplicationModel model, 28public DistributedApplicationModel Model { get; } = model; 60internal async Task WriteModelAsync(DistributedApplicationModel model)
Aspire.Hosting.Azure (8)
AzurePublishingContext.cs (2)
63public async Task WriteModelAsync(DistributedApplicationModel model, AzureEnvironmentResource environment, CancellationToken cancellationToken = default) 79private Task WriteAzureArtifactsOutputAsync(DistributedApplicationModel model, AzureEnvironmentResource environment, CancellationToken _)
AzureResourcePreparer.cs (5)
23public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken) 51internal static List<(IResource Resource, IAzureResource AzureResource)> GetAzureResourcesFromAppModel(DistributedApplicationModel appModel) 88private static void EnsureNoRoleAssignmentAnnotations(DistributedApplicationModel appModel) 99private async Task BuildRoleAssignmentAnnotations(DistributedApplicationModel appModel, List<(IResource Resource, IAzureResource AzureResource)> azureResources, AzureProvisioningOptions options, CancellationToken cancellationToken) 432private void CreateGlobalRoleAssignments(DistributedApplicationModel appModel, Dictionary<AzureProvisioningResource, HashSet<RoleDefinition>> globalRoleAssignments, AzureProvisioningOptions provisioningOptions)
Provisioning\Provisioners\AzureProvisioner.cs (1)
46public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
Aspire.Hosting.Azure.AppContainers (1)
AzureContainerAppsInfrastructure.cs (1)
23public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
Aspire.Hosting.Azure.AppService (1)
AzureAppServiceInfrastructure.cs (1)
17public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
Aspire.Hosting.Azure.Tests (157)
AzureAppServiceTests.cs (10)
36var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 66var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 94var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 132var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 160var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureBicepProvisionerTests.cs (2)
277var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureBicepResourceTests.cs (16)
252var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 289var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 515var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1145var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1211var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1514var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1739var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1870var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureContainerAppsTests.cs (68)
39var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 74var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 105var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 148var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 181var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 226var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 257var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 329var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 407var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 442var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 506var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 543var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 582var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 623var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 656var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 709var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 782var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 826var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 858var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 891var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 921var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 959var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1004var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1046var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1085var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1106var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1125var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1145var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1164var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1183var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1201var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1227var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1273var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 1331var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureContainerRegistryTests.cs (6)
29var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 51var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 88var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureCosmosDBExtensionsTests.cs (2)
200var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureEventHubsExtensionsTests.cs (2)
289var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureFunctionsTests.cs (14)
160var model = host.Services.GetRequiredService<DistributedApplicationModel>(); 186var model = host.Services.GetRequiredService<DistributedApplicationModel>(); 284var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 314var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 341var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 369var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 399var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureKeyVaultTests.cs (2)
35var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureManifestUtils.cs (2)
17public static Task<(JsonNode ManifestNode, string BicepText)> GetManifestWithBicep(DistributedApplicationModel appModel, IResource resource) => 20private static async Task<(JsonNode ManifestNode, string BicepText)> GetManifestWithBicep(DistributedApplicationModel appModel, IResource resource, bool skipPreparer)
AzurePostgresExtensionsTests.cs (4)
36var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 59var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureRedisExtensionsTests.cs (4)
37var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 57var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureResourcePreparerTests.cs (4)
61var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 107var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureSignalRExtensionsTests.cs (4)
21var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 43var model = app.Services.GetRequiredService<DistributedApplicationModel>();
AzureUserAssignedIdentityTests.cs (6)
29var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 49var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 71var model = app.Services.GetRequiredService<DistributedApplicationModel>();
ContainerRegistryTests.cs (7)
29var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 59var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 99var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 145public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
ExistingAzureResourceTests.cs (2)
76var model = app.Services.GetRequiredService<DistributedApplicationModel>();
RoleAssignmentTests.cs (2)
190var model = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Containers.Tests (13)
ContainerResourceTests.cs (13)
22var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 41var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 60var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 80var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 155var containerResource = Assert.Single(app.Services.GetRequiredService<DistributedApplicationModel>().GetContainerResources()); 189var containerResource = Assert.Single(app.Services.GetRequiredService<DistributedApplicationModel>().GetContainerResources()); 217var containerResource = Assert.Single(app.Services.GetRequiredService<DistributedApplicationModel>().GetContainerResources()); 236var containerResource = Assert.Single(app.Services.GetRequiredService<DistributedApplicationModel>().GetContainerResources()); 285var containerResource = Assert.Single(app.Services.GetRequiredService<DistributedApplicationModel>().GetContainerResources());
Aspire.Hosting.Docker (3)
DockerComposeInfrastructure.cs (1)
18public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
DockerComposePublishingContext.cs (2)
33internal async Task WriteModelAsync(DistributedApplicationModel model, DockerComposeEnvironmentResource environment) 57private async Task WriteDockerComposeOutputAsync(DistributedApplicationModel model, DockerComposeEnvironmentResource environment)
Aspire.Hosting.Garnet.Tests (12)
AddGarnetTests.cs (12)
23var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 51var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 80var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 344var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 365var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 382var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Kafka.Tests (4)
AddKafkaTests.cs (4)
23var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 65var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Keycloak.Tests (2)
KeycloakResourceBuilderTests.cs (2)
24var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Kubernetes (3)
KubernetesInfrastructure.cs (1)
18public async Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
KubernetesPublishingContext.cs (2)
44internal async Task WriteModelAsync(DistributedApplicationModel model, KubernetesEnvironmentResource environment) 68private async Task WriteKubernetesOutputAsync(DistributedApplicationModel model, KubernetesEnvironmentResource environment)
Aspire.Hosting.Milvus.Tests (6)
AddMilvusTests.cs (6)
26var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 56var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 185var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.MongoDB.Tests (6)
AddMongoDBTests.cs (6)
24var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 52var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 83var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.MySql.Tests (12)
AddMySqlTests.cs (12)
44var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 83var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 121var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 140var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 242await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 272var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 274builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>()));
Aspire.Hosting.Nats.Tests (8)
AddNatsTests.cs (8)
47var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 76var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 94var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 136var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Oracle.Tests (10)
AddOracleTests.cs (10)
43var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 82var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 120var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 140var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 163var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.PostgreSQL (4)
PostgresBuilderExtensions.cs (4)
208var appModel = context.ServiceProvider.GetRequiredService<DistributedApplicationModel>(); 317var appModel = context.ServiceProvider.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.PostgreSQL.Tests (15)
AddPostgresTests.cs (15)
53var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 107var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 175var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 197var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 378var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 381await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 471await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 541var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 543await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>()));
Aspire.Hosting.Python.Tests (6)
AddPythonAppTests.cs (6)
145var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 181var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 220var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Qdrant.Tests (8)
AddQdrantTests.cs (8)
46var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 85var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 118var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 284var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.RabbitMQ.Tests (6)
AddRabbitMQTests.cs (6)
51var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 103var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 142var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Redis.Tests (20)
AddRedisTests.cs (18)
31var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 59var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 90var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 107var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 122var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 269await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 407var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 426await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 450await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 471await builder.Eventing.PublishAsync<AfterEndpointsAllocatedEvent>(new(app.Services, app.Services.GetRequiredService<DistributedApplicationModel>())); 623var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
RedisFunctionalTests.cs (2)
606var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Seq.Tests (6)
AddSeqTests.cs (6)
22var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 50var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 79var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.SqlServer.Tests (8)
AddSqlServerTests.cs (8)
44var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 91var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 113var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 277var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Testing (2)
DistributedApplicationHostingTestingExtensions.cs (2)
78var applicationModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Testing.Tests (6)
TestingBuilderTests.cs (4)
99var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 161var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
TestingFactoryTests.cs (2)
43var appModel = _app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Tests (172)
AddParameterTests.cs (16)
25var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 62var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 96var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 146var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 203var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 268var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 298var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 336var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Backchannel\AppHostBackchannelTests.cs (1)
147public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
Dashboard\DashboardLifecycleHookTests.cs (3)
47var model = new DistributedApplicationModel(new ResourceCollection()); 88var model = new DistributedApplicationModel(new ResourceCollection()); 136var model = new DistributedApplicationModel(new ResourceCollection());
Dashboard\DashboardResourceTests.cs (26)
47var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 71var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 104var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 176var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 214var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 251var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 285var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 321var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 365var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 390var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 406var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 471var model = app.Services.GetRequiredService<DistributedApplicationModel>(); 523var model = app.Services.GetRequiredService<DistributedApplicationModel>();
Dcp\DcpExecutorTests.cs (59)
35var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 60var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 144var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 187var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 236var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 268var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 300var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 333var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 370var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 390var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 424var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 458var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 522var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 544var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 580var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 678var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 784var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 829var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 866var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 901var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 961var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 982var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1018var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1055var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1092var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1122var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1159var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1181var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1216var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 1244DistributedApplicationModel distributedAppModel,
DistributedApplicationBuilderTests.cs (4)
42var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 64var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
DistributedApplicationRunnerTests.cs (1)
33public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
DistributedApplicationTests.cs (6)
341var tcs = new TaskCompletionSource<DistributedApplicationModel>(TaskCreationOptions.RunContinuationsAsynchronously); 348var appModel = await tcs.Task.DefaultTimeout(TestConstants.DefaultOrchestratorTestTimeout); 359private sealed class CheckAllocatedEndpointsLifecycleHook(TaskCompletionSource<DistributedApplicationModel> tcs) : IDistributedApplicationLifecycleHook 361public Task AfterEndpointsAllocatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default) 1216public async Task AfterEndpointsAllocatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken) 1221public async Task AfterResourcesCreatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken)
Helpers\CallbackLifecycleHook.cs (3)
10private readonly Func<DistributedApplicationModel, CancellationToken, Task> _beforeStartCallback; 12public CallbackLifecycleHook(Func<DistributedApplicationModel, CancellationToken, Task> beforeStartCallback) 17public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
Helpers\JsonDocumentManifestPublisher.cs (1)
18protected override async Task PublishInternalAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
Helpers\NoopPublisher.cs (1)
9public Task PublishAsync(DistributedApplicationModel model, CancellationToken cancellationToken)
KestrelConfigTests.cs (2)
360var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Orchestrator\ApplicationOrchestratorTests.cs (15)
27var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 74var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 119var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 162var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 229var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 281var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 351var distributedAppModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 388DistributedApplicationModel distributedAppModel,
Orchestrator\RelationshipEvaluatorTests.cs (2)
29var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
ProjectResourceTests.cs (30)
72var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 186var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 213var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 231var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 247var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 297var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 317var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 360var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 382var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 407var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 437var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 456var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 480var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 530var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 625var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
WithEndpointTests.cs (2)
210var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Hosting.Valkey.Tests (12)
AddValkeyTests.cs (12)
23var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 51var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 80var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 99var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 116var appModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 334var appModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Aspire.Playground.Tests (7)
AppHostTests.cs (2)
68var applicationModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Infrastructure\DistributedApplicationExtensions.cs (4)
104var applicationModel = app.Services.GetRequiredService<DistributedApplicationModel>(); 133var applicationModel = app.Services.GetRequiredService<DistributedApplicationModel>();
Infrastructure\DistributedApplicationTestFactory.cs (1)
53public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
CustomResources.AppHost (1)
TestResource.cs (1)
34public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
HealthChecksSandbox.AppHost (1)
Program.cs (1)
65public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken)
Stress.AppHost (1)
TestResource.cs (1)
53public Task BeforeStartAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken = default)
TestProject.AppHost (1)
TestProgram.cs (1)
158public async Task AfterEndpointsAllocatedAsync(DistributedApplicationModel appModel, CancellationToken cancellationToken)