Dependency injection and service registration patterns.
Run code when the host is starting, started, stopping and stopped, without writing a hosted service, from an application builder or a service collection.