32 references to PublishAsync
Aspire.Hosting (18)
Dcp\DcpExecutor.cs (18)
147await _executorEvents.PublishAsync(new OnResourcesPreparedContext(cancellationToken)).ConfigureAwait(false); 402await _executorEvents.PublishAsync(new OnResourceChangedContext(_shutdownCancellation.Token, resourceType, appModelResource, resource.Metadata.Name, status, s => snapshotFactory(resource, s))).ConfigureAwait(false); 672await _executorEvents.PublishAsync(new OnResourceChangedContext(_shutdownCancellation.Token, resourceKind, appModelResource, resourceName, status, s => 803await _executorEvents.PublishAsync(new OnEndpointsAllocatedContext(cancellationToken)).ConfigureAwait(false); 1124await _executorEvents.PublishAsync(new OnResourceChangedContext( 1131await _executorEvents.PublishAsync(new OnResourceStartingContext(cancellationToken, resourceType, resource, DcpResourceName: null)).ConfigureAwait(false); 1137await _executorEvents.PublishAsync(new OnResourceChangedContext(cancellationToken, resourceType, resource, er.DcpResource.Metadata.Name, new ResourceStatus(KnownResourceStates.NotStarted, null, null), s => s with { State = new ResourceStateSnapshot(KnownResourceStates.NotStarted, null) })).ConfigureAwait(false); 1150await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, resourceType, er.ModelResource, er.DcpResource.Metadata.Name)).ConfigureAwait(false); 1158await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, resourceType, er.ModelResource, er.DcpResource.Metadata.Name)).ConfigureAwait(false); 1169await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, resourceType, resource, DcpResourceName: null)).ConfigureAwait(false); 1405await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, KnownResourceTypes.Container, cr.ModelResource, cr.DcpResourceName)).ConfigureAwait(false); 1410await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, KnownResourceTypes.Container, cr.ModelResource, cr.DcpResourceName)).ConfigureAwait(false); 1446await _executorEvents.PublishAsync(new OnResourceChangedContext(_shutdownCancellation.Token, KnownResourceTypes.Container, cr.ModelResource, cr.DcpResourceName, new ResourceStatus(null, null, null), s => _snapshotBuilder.ToSnapshot((Container)cr.DcpResource, s))).ConfigureAwait(false); 1470await _executorEvents.PublishAsync(new OnResourceStartingContext(cancellationToken, KnownResourceTypes.Container, cr.ModelResource, cr.DcpResource.Metadata.Name)).ConfigureAwait(false); 1829await _executorEvents.PublishAsync(new OnResourceStartingContext(cancellationToken, resourceType, appResource.ModelResource, appResource.DcpResourceName)).ConfigureAwait(false); 1835await _executorEvents.PublishAsync(new OnResourceStartingContext(cancellationToken, resourceType, appResource.ModelResource, appResource.DcpResourceName)).ConfigureAwait(false); 1848await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, resourceType, appResource.ModelResource, appResource.DcpResourceName)).ConfigureAwait(false); 1853await _executorEvents.PublishAsync(new OnResourceFailedToStartContext(cancellationToken, resourceType, appResource.ModelResource, appResource.DcpResourceName)).ConfigureAwait(false);
Aspire.Hosting.Tests (14)
Orchestrator\ApplicationOrchestratorTests.cs (14)
59await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 106await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 146await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 213await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 273await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 320await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 389await events.PublishAsync(new OnResourceStartingContext(CancellationToken.None, KnownResourceTypes.Container, parentResource.Resource, parentResource.Resource.Name)); 574await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 577await events.PublishAsync(new OnResourceChangedContext( 620await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 623await events.PublishAsync(new OnResourceChangedContext( 694await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 750await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None)); 799await events.PublishAsync(new OnResourcesPreparedContext(CancellationToken.None));