revsys / django-health-check

a pluggable app that runs a full check on the deployment, using a number of plugins to check e.g. database, queue server, celery processes, etc.

Home Page:https://readthedocs.org/projects/django-health-check/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Custom error reporter or filter

sevdog opened this issue · comments

Using django-health-check in conjunction with AdminEmailHandler log handler for error reports may produce usless report emails.

This is due to the fact that a single failed heath check produces a 500 response which is logged at level ERROR by django and thus getting caught by the handler which is usally used in that way.

It would be nice to have in this library:

  • a custom error reporter to be used as DEFAULT_EXCEPTION_REPORTER or as request.exception_reporter_class to provide more useful information to those which have configured this report
  • a custom log Filter to be used by those which do not want to be advised by health checks when using a logger