View Source BtrzHealthchecker.Checkers.Postgres (BtrzHealthchecker v0.4.0)
Defines the Postgres status checker.
Link to this section Summary
Functions
Returns the status of the postgres service querying by all the tables of the catalog
Returns the name of the service
Link to this section Functions
Returns the status of the postgres service querying by all the tables of the catalog
Returns 200 if the conection is reachable and the check query can be executed.
Returns 500 in case of Postgrex.Error or other like ArgumentError, DBConnection.ConnectionError, DBConnection.OwnershipError or RuntimeError.
examples
Examples
iex> BtrzHealthchecker.Checkers.Postgres.check_status(opts)
200
iex> BtrzHealthchecker.Checkers.Postgres.check_status(bad_opts)
500
Returns the name of the service
Returns "postgres".