HealthCheckService¶
- class gafaelfawr.services.health.HealthCheckService(*, token_db_store, token_redis_store, user_info_service)¶
Bases:
object
Check the health of the Gafaelfawr service.
Intended to be invoked via a Kubernetes liveness check and test the underlying Redis, database, and LDAP connections.
- Parameters:
token_db_store (
TokenDatabaseStore
) – Database backing store for tokens.token_redis_store (
TokenRedisStore
) – Redis backing store for tokens.user_info_service (
UserInfoService
) – Service for retrieving user information from LDAP and Firestore.
Methods Summary
check
(*[, check_user_info])Check the health of the underlying database and Redis.
Methods Documentation
- async check(*, check_user_info=True)¶
Check the health of the underlying database and Redis.
Raises an exception of some kind if one of the underlying services is unavailable.