9 instantiations of BeforeStartEvent
Aspire.Hosting (1)
DistributedApplication.cs (1)
489
var beforeStartEvent = new
BeforeStartEvent
(_host.Services, _host.Services.GetRequiredService<DistributedApplicationModel>());
Aspire.Hosting.Azure.Tests (1)
AzureManifestUtils.cs (1)
27
await azurePreparer.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), appModel), cancellationToken: default);
Aspire.Hosting.Tests (7)
Dashboard\DashboardLifecycleHookTests.cs (7)
46
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None).DefaultTimeout();
89
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None).DefaultTimeout();
137
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None).DefaultTimeout();
237
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None);
325
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None);
397
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None);
467
await hook.OnBeforeStartAsync(new
BeforeStartEvent
(new TestServiceProvider(), model), CancellationToken.None);
45 references to BeforeStartEvent
Aspire.Hosting (15)
ApplicationModel\BeforeStartEvent.cs (1)
20
/// Subscribe to the <see cref="
BeforeStartEvent
"/> event and resolve the distributed application model.
BuiltInDistributedApplicationEventSubscriptionHandlers.cs (4)
12
public static Task InitializeDcpAnnotations(
BeforeStartEvent
beforeStartEvent, CancellationToken _)
41
public static Task ExcludeDashboardFromManifestAsync(
BeforeStartEvent
beforeStartEvent, CancellationToken _)
52
public static Task MutateHttp2TransportAsync(
BeforeStartEvent
beforeStartEvent, CancellationToken _)
67
public static Task UpdateContainerRegistryAsync(
BeforeStartEvent
@event, DistributedApplicationOptions options)
Dashboard\DashboardEventHandlers.cs (2)
61
public Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken)
788
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
DistributedApplication.cs (1)
489
var
beforeStartEvent = new BeforeStartEvent(_host.Services, _host.Services.GetRequiredService<DistributedApplicationModel>());
DistributedApplicationBuilder.cs (5)
238
Eventing.Subscribe<
BeforeStartEvent
>(ExecEventingHandlers.InitializeExecResources);
390
Eventing.Subscribe<
BeforeStartEvent
>(BuiltInDistributedApplicationEventSubscriptionHandlers.InitializeDcpAnnotations);
394
Eventing.Subscribe<
BeforeStartEvent
>(BuiltInDistributedApplicationEventSubscriptionHandlers.MutateHttp2TransportAsync);
403
Eventing.Subscribe<
BeforeStartEvent
>(BuiltInDistributedApplicationEventSubscriptionHandlers.ExcludeDashboardFromManifestAsync);
408
Eventing.Subscribe<
BeforeStartEvent
>((e, ct) => BuiltInDistributedApplicationEventSubscriptionHandlers.UpdateContainerRegistryAsync(e, options));
Exec\ExecEventingHandlers.cs (1)
11
public static Task InitializeExecResources(
BeforeStartEvent
beforeStartEvent, CancellationToken _)
ResourceBuilderExtensions.cs (1)
1927
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>((e, ct) =>
Aspire.Hosting.Azure (4)
AzureResourcePreparer.cs (2)
23
public async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken)
544
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Provisioning\Provisioners\AzureProvisioner.cs (2)
30
private async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
289
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Aspire.Hosting.Azure.AppContainers (2)
AzureContainerAppsInfrastructure.cs (2)
23
private async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
75
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Aspire.Hosting.Azure.AppService (2)
AzureAppServiceInfrastructure.cs (2)
18
private async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
75
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Aspire.Hosting.Azure.CosmosDB (1)
AzureCosmosDBExtensions.cs (1)
400
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>((data, _) =>
Aspire.Hosting.Azure.Functions (1)
AzureFunctionsProjectResourceExtensions.cs (1)
63
builder.Eventing.Subscribe<
BeforeStartEvent
>((data, token) =>
Aspire.Hosting.Azure.PostgreSQL (1)
AzurePostgresExtensions.cs (1)
300
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>((data, token) =>
Aspire.Hosting.Azure.Redis (2)
AzureRedisEnterpriseExtensions.cs (1)
141
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>((data, token) =>
AzureRedisExtensions.cs (1)
206
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>((data, token) =>
Aspire.Hosting.Docker (3)
DockerComposeInfrastructure.cs (3)
14
/// Implements <see cref="IDistributedApplicationEventingSubscriber"/> and subscribes to <see cref="
BeforeStartEvent
"/> to configure Docker Compose resources before publish.
20
private async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
100
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Aspire.Hosting.Kubernetes (3)
KubernetesInfrastructure.cs (3)
13
/// Implements <see cref="IDistributedApplicationEventingSubscriber"/> and subscribes to <see cref="
BeforeStartEvent
"/> to configure Kubernetes resources before publish.
19
private async Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
68
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Aspire.Hosting.Tests (2)
Eventing\DistributedApplicationBuilderEventingTests.cs (1)
232
builder.Eventing.Subscribe<
BeforeStartEvent
>((e, ct) =>
OperationModesTests.cs (1)
112
builder.Eventing.Subscribe<
BeforeStartEvent
>((e, ct) => {
Aspire.Playground.Tests (2)
Infrastructure\DistributedApplicationTestFactory.cs (2)
54
public Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
74
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
AspireWithNode.AppHost (1)
DevCertHostingExtensions.cs (1)
25
builder.ApplicationBuilder.Eventing.Subscribe<
BeforeStartEvent
>(async (e, ct) =>
CustomResources.AppHost (2)
TestResource.cs (2)
38
public Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
86
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
HealthChecksSandbox.AppHost (2)
Program.cs (2)
66
public Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken)
87
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);
Stress.AppHost (2)
TestResource.cs (2)
57
public Task OnBeforeStartAsync(
BeforeStartEvent
@event, CancellationToken cancellationToken = default)
104
eventing.Subscribe<
BeforeStartEvent
>(OnBeforeStartAsync);