pub async fn check_health(&self) -> AppHealth {
        // Clone `inner` so that we don't hold a lock for them across a wait point.
        let AppHealthCheckInner {
            components,
            app_details,
            slow_time_limit,
            hard_time_limit,
        } = self
            .inner
            .lock()
            .expect("`AppHealthCheck` is poisoned")
            .clone();

        let check_futures = components.iter().map(|check| {
            Self::check_health_with_time_limit(check.as_ref(), slow_time_limit, hard_time_limit)
        });
        let components: HashMap<_, _> = future::join_all(check_futures).await.into_iter().collect();

        let aggregated_status = components
            .values()
            .map(|health| health.status)
            .max_by_key(|status| status.priority_for_aggregation())
            .unwrap_or(HealthStatus::Ready);
        let mut inner = Health::from(aggregated_status);
        inner.details = app_details.clone();

        let health = AppHealth { inner, components };
        if !health.inner.status.is_healthy() {
            // Only log non-ready application health so that logs are not spammed without a reason.
            tracing::debug!("Aggregated application health: {health:?}");
        }
        health
    }
Checks the overall application health. This will query all component checks concurrently.
core/lib/health_check/src/lib.rs