1 implementation of PublishAsync
Aspire.Hosting (1)
Eventing\DistributedApplicationEventing.cs (1)
25public async Task PublishAsync<T>(T @event, EventDispatchBehavior dispatchBehavior, CancellationToken cancellationToken = default) where T : IDistributedApplicationEvent
15 references to PublishAsync
Aspire.Hosting (5)
Backchannel\AuxiliaryBackchannelService.cs (1)
131await eventing.PublishAsync(
Backchannel\BackchannelService.cs (2)
68await eventing.PublishAsync( 93await eventing.PublishAsync(
Orchestrator\ApplicationOrchestrator.cs (2)
219await eventing.PublishAsync(endpointEvent, dispatchBehavior, cancellationToken).ConfigureAwait(false); 797await _eventing.PublishAsync(initializeEvent, EventDispatchBehavior.NonBlockingConcurrent, cancellationToken).ConfigureAwait(false);
Aspire.Hosting.DevTunnels (2)
DevTunnelResourceBuilderExtensions.cs (2)
224await eventing.PublishAsync<BeforeResourceStartedEvent>(new(portResource, e.Services), EventDispatchBehavior.NonBlockingConcurrent, ct).ConfigureAwait(false); 847.PublishAsync(new ResourceStoppedEvent(portResource, services, new(portResource, portResource.Name, stoppedSnapshot!)),
Aspire.Hosting.Kafka.Tests (1)
AddKafkaTests.cs (1)
294await appBuilder.Eventing.PublishAsync(
Aspire.Hosting.MySql.Tests (1)
AddMySqlTests.cs (1)
423await appBuilder.Eventing.PublishAsync(
Aspire.Hosting.Tests (6)
Eventing\DistributedApplicationBuilderEventingTests.cs (5)
38await builder.Eventing.PublishAsync(new DummyEvent(), EventDispatchBehavior.NonBlockingConcurrent, cts.Token).DefaultTimeout(); 72var pendingPublish = builder.Eventing.PublishAsync(new DummyEvent(), EventDispatchBehavior.BlockingSequential); 105var pendingPublish = builder.Eventing.PublishAsync(new DummyEvent(), EventDispatchBehavior.BlockingConcurrent); 137await builder.Eventing.PublishAsync(new DummyEvent(), EventDispatchBehavior.NonBlockingConcurrent).DefaultTimeout(); 172await builder.Eventing.PublishAsync(new DummyEvent(), EventDispatchBehavior.NonBlockingSequential).DefaultTimeout();
WithUrlsTests.cs (1)
91await e.Eventing.PublishAsync(new BeforeResourceStartedEvent(custom, e.Services), EventDispatchBehavior.BlockingSequential, ct);