INNER CODE UNIT · Python

check_health

asacristani/fastapi-rocket-boilerplate · app/main.py:67

async def check_health():
    """
    Check all the services in the infrastructure are working
    """
    ok_code = "running"
    ko_code = "down"

    # DB check
    db_status = check_db_connection()
    if db_status:
        db_status = ok_code
    else:
        db_status = ko_code

    # Celery check
    celery_status = celery.control.inspect().ping()
    if celery_status:
        celery_status = ok_code

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…