This repository has been archived on 2020-03-24. You can view files and clone it, but cannot push or open issues or pull requests.
quay/health/models_interface.py

15 lines
388 B
Python
Raw Normal View History

2017-07-11 10:48:25 +00:00
from abc import ABCMeta, abstractmethod
from six import add_metaclass
2017-07-11 10:48:55 +00:00
2017-07-11 10:48:25 +00:00
@add_metaclass(ABCMeta)
class HealthCheckDataInterface(object):
"""
Interface that represents all data store interactions required by health checks.
"""
2017-07-11 10:48:55 +00:00
2017-07-11 10:48:25 +00:00
@abstractmethod
def check_health(self, app_config):
""" Returns True if the connection to the database is healthy and False otherwise. """
pass