Open
Description
Current runtime lifecycle processing:
DistributedApplication.StartAsync
IDistributedApplicationEventing -> BeforeStartEvent
- The
DistributedApplication.Services
collection is built by the time this event is published - This event is the last chance to add or remove resources from the
DistributedApplicationModel
before they're processed by consumers (note you'll likely want to capture theIDistributedApplicationBuilder
before this so that you can get instances ofIResourceBuilder<TResource>
if adding resources)
- The
IDistibutedApplicationLifecycleHook.BeforeStartAsync
- NEW EVENT:
IDistributedApplicationEventing -> InitializeResourceEvent
IDistributedApplicationEventing -> EndpointsAllocatedEvent
IDistibutedApplicationLifecycleHook.EndpointsAllocatedAsync
- Per DCP controlled resources:
IDistributedApplicationEventing -> ConnectionStringAvailableEvent
IDistributedApplicationEventing -> BeforeResourceStartedEvent
- This even can be fired multiple times for a resource, e.g. if it's restarted it will fire each time before it starts
- This event is the last chance to mutate a resource's annotations before they're processed by consumers
- The logic for
WaitFor
is implemented here, so resources must publish this event
IDistributedApplicationEventing -> ResourceReadyEvent
- fires for all resources after health checks are healthy, only once
- Resources that have a
WaitFor
relationship to another resource are waiting for this event
IDistributedApplicationEventing -> AfterResourcesCreatedEvent
IDistibutedApplicationLifecycleHook.AfterResourcesCreatedAsync