Sentry Process

LICENSE pipeline status Crates.io Version Minimum rustc version Get help on Codementor

Report failed processes/scripts to Sentry.

⚠️ Main repository is here: https://gitlab.com/dsferruzza/sentry-process ⚠️

Motivation

Sentry is a cool system that helps developers to aggregate, monitor and fix errors/exceptions in their own apps. It has integrations for many technologies so that reported errors can contain relevant informations.

But sometimes it can be desirable to plug Sentry to an abritrary process. Such process can be a binary that was built without Sentry support, or a Bash script that runs every night on a server, for example.

With Sentry Process it is now easy to launch a process that will send an event to a Sentry instance whenever it fails!

How to use

If running COMMAND [ARGUMENTS]... results in an exit code that is not 0, Sentry Process considers it as a failure and reports. For example, sentry-process false will report whereas sentry-process true will not.

The exit code, standard output and standard error of COMMAND [ARGUMENTS]... are re-emmited by sentry-process COMMAND [ARGUMENTS]..., so that it can be piped or used by other programs. In fact, standard output and standard error are streamed so you can run (for example) sentry-process wget https://somebigfileurl and see the progress just like if you had run wget https://somebigfileurl.

Rust Version Requirements

Sentry Process needs Rust 1.32+ to be compiled.

Limitations

License

MIT License Copyright (c) 2019 David Sferruzza