1 implementation of Subscribe
Aspire.Hosting (1)
Eventing\DistributedApplicationEventing.cs (1)
77public DistributedApplicationEventSubscription Subscribe<T>(Func<T, CancellationToken, Task> callback) where T : IDistributedApplicationEvent
39 references to Subscribe
Aspire.Cli.Tests (1)
Hosting\CliOrphanDetectorTests.cs (1)
106builder.Eventing.Subscribe<AfterResourcesCreatedEvent>((e, ct) => {
Aspire.Hosting (13)
DistributedApplicationBuilder.cs (5)
236Eventing.Subscribe<BeforeStartEvent>(ExecEventingHandlers.InitializeExecResources); 387Eventing.Subscribe<BeforeStartEvent>(BuiltInDistributedApplicationEventSubscriptionHandlers.InitializeDcpAnnotations); 391Eventing.Subscribe<BeforeStartEvent>(BuiltInDistributedApplicationEventSubscriptionHandlers.MutateHttp2TransportAsync); 400Eventing.Subscribe<BeforeStartEvent>(BuiltInDistributedApplicationEventSubscriptionHandlers.ExcludeDashboardFromManifestAsync); 405Eventing.Subscribe<BeforeStartEvent>((e, ct) => BuiltInDistributedApplicationEventSubscriptionHandlers.UpdateContainerRegistryAsync(e, options));
Eventing\DistributedApplicationEventing.cs (2)
76/// <inheritdoc cref="IDistributedApplicationEventing.Subscribe{T}(Func{T, CancellationToken, Task})" /> 105/// <inheritdoc cref="IDistributedApplicationEventing.Subscribe{T}(Func{T, CancellationToken, Task})" />
Orchestrator\ApplicationOrchestrator.cs (4)
58_eventing.Subscribe<ResourceEndpointsAllocatedEvent>(OnResourceEndpointsAllocated); 59_eventing.Subscribe<ConnectionStringAvailableEvent>(PublishConnectionStringValue); 61_eventing.Subscribe<BeforeResourceStartedEvent>(WaitForInBeforeResourceStartedEvent); 62_eventing.Subscribe<InitializeResourceEvent>(OnResourceInitialized);
PublisherDistributedApplicationBuilderExtensions.cs (1)
29builder.Eventing.Subscribe<PublisherAdvertisementEvent>((e, ct) => {
ResourceBuilderExtensions.cs (1)
1787builder.ApplicationBuilder.Eventing.Subscribe<BeforeStartEvent>((e, ct) =>
Aspire.Hosting.Azure.CosmosDB (1)
AzureCosmosDBExtensions.cs (1)
397builder.ApplicationBuilder.Eventing.Subscribe<BeforeStartEvent>((data, _) =>
Aspire.Hosting.Azure.Functions (1)
AzureFunctionsProjectResourceExtensions.cs (1)
63builder.Eventing.Subscribe<BeforeStartEvent>((data, token) =>
Aspire.Hosting.Azure.PostgreSQL (1)
AzurePostgresExtensions.cs (1)
300builder.ApplicationBuilder.Eventing.Subscribe<BeforeStartEvent>((data, token) =>
Aspire.Hosting.Azure.Redis (1)
AzureRedisExtensions.cs (1)
206builder.ApplicationBuilder.Eventing.Subscribe<BeforeStartEvent>((data, token) =>
Aspire.Hosting.Tests (21)
Backchannel\AppHostBackchannelTests.cs (4)
25builder.Eventing.Subscribe<BackchannelReadyEvent>((e, ct) => { 31builder.Eventing.Subscribe<BackchannelConnectedEvent>((e, ct) => { 61builder.Eventing.Subscribe<BackchannelReadyEvent>((e, ct) => { 104builder.Eventing.Subscribe<BackchannelReadyEvent>((e, ct) => {
DistributedApplicationTests.cs (1)
620events.Subscribe<BeforeResourceStartedEvent>(async (e, ct) =>
Eventing\DistributedApplicationBuilderEventingTests.cs (12)
24builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 31builder.Eventing.Subscribe<DummyEvent>((@event, ct) => 56builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 63builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 88builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 95builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 121builder.Eventing.Subscribe<DummyEvent>(async (@event, ct) => 130builder.Eventing.Subscribe<DummyEvent>((@event, ct) => 208builder.Eventing.Subscribe<BeforeResourceStartedEvent>((e, ct) => 233builder.Eventing.Subscribe<BeforeStartEvent>((e, ct) => 241builder.Eventing.Subscribe<AfterEndpointsAllocatedEvent>((e, ct) => 249builder.Eventing.Subscribe<AfterResourcesCreatedEvent>((e, ct) =>
OperationModesTests.cs (4)
24builder.Eventing.Subscribe<AfterResourcesCreatedEvent>((e, ct) => { 53builder.Eventing.Subscribe<AfterResourcesCreatedEvent>((e, ct) => { 82builder.Eventing.Subscribe<AfterResourcesCreatedEvent>((e, ct) => { 113builder.Eventing.Subscribe<BeforeStartEvent>((e, ct) => {