Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integration with the Laravel Exception Handler #25

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

tortuetorche
Copy link
Contributor

@tortuetorche tortuetorche commented Dec 16, 2020

If the report() Laravel helper is present, otherwise do nothing.

This feature is disabled by default, here how to enable it for Healthz failure and warning exceptions:

    return (new Healthz([$env, $debugCheck, $db]))
        ->setReportFailure(true)
        ->setReportWarning(true);

Then it can report Healthz failure and warning exceptions to the Laravel log exceptions or send them to an external service like Flare, Bugsnag or Sentry.

Reference: https://laravel.com/docs/8.x/errors

Usage:
    return (new Healthz([$env, $debugCheck, $db]))
        ->setReportFailure(true)->setReportWarning(true);

Reference: https://laravel.com/docs/8.x/errors
@Olofguard
Copy link
Member

@tortuetorche I do think this a valuable addition. Would you mind adding some tests around these new methods?

@tortuetorche
Copy link
Contributor Author

tortuetorche commented Jul 2, 2021

@tortuetorche I do think this a valuable addition. Would you mind adding some tests around these new methods?

Done ✅

Build passing on my repository: https://app.travis-ci.com/github/tortuetorche/php-healthz/builds/231665384
Builds on your repository looks disabled (maybe since the Travis CI repositories migration...)

@tortuetorche
Copy link
Contributor Author

Hi @Olofguard,

Is is OK for you?
I'll try to add some documentation about this feature in README.md , this week, then it will be ready for review and hopefully for merge 🤞

Have a good day,
Tortue Torche

@tortuetorche
Copy link
Contributor Author

Hi @Olofguard,

This pull request is now ready for review 🕵️ then for merge 🚀!

Have a good day,
Tortue Torche

@tortuetorche
Copy link
Contributor Author

Hi @Olofguard,

Any news on reviewing this pull request?

Have a good week,
Tortue Torche

@tenshiAMD
Copy link
Contributor

@tortuetorche this looks like a great addition. 👍 I'm also using external services like Sentry so this will be helpful.

@Olofguard would you mind checking this again? Thank you.

@Olofguard
Copy link
Member

Yup I’ll try to prioritize this tomorrow. Apologies for the delay, our team over here has shrunk significantly.

@tenshiAMD
Copy link
Contributor

@Olofguard A gentle follow-up regarding this one. Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants