A package for sentry.io integration - looking for testers

A little while ago I wrote a package SentryIntegration.jl to interface with Sentry (https://sentry.io) and I wanted to let people know of it in case it helps others and to get some feedback.

A quick description on Sentry: it is primarily for production environments where monitoring of issues is both essential and clunky. Sentry allows for errors to be quickly bubbled up and acted on. Two simple examples of usage in our company:

  • A generic “catch-all” of any unhandled exception can produce a email to relevant developers + a message in the developers channel of our slack chat.
  • We use it with a service that runs after modifications to the database to check for errors in our data structure.

A while ago, I wrote a websocket server for use in our company to answer database queries and decided to use Julia. It worked out very well and I’m pleased to have taken the plunge there.

We have Sentry integrated in our our JS and Python parts of our stack, however there is no official Sentry API for Julia. So I decided to write my own. This is the result.

An example of usage:

# App start - with SENTRY_DSN env var set.

# Optional global tags
SentryIntegration.set_tag("customer", customer)
SentryIntegration.set_tag("release", string(VERSION))

# Capturing an exception:
catch exc

# Manual message:
  "Some important error",
  attachments=["e.g. JSON"]

I also put in some basic support for transactions/spans for Sentry tracing:

                            name="Name of overall transaction",
                            op="span name, e.g. 'handle web request'",
                            tags=[:url => some_url]) do t
    # Inner function whose logical operation is captured by the name "op"
    # and whose time is to be recorded. This is a "span" in Sentry.
    SentryIntegration.start_transaction(; op="database query") do t
        # This is a nested span in the transaction.

I am not doing a full package release/announcement as a) I suspect this package would break in any environment/use-case that is not our exact one and b) I have had no time to document it. I am looking for anyone interested in testing this out and if there is any interest, I would commit more time to bringing the package up to scratch.


HI Pengwyn,

I’m interested in helping out here.

1 Like

Great! Are you using sentry in one of your projects? I think testing it out, and seeing if it fits in nicely or if it breaks, is the first thing I’d love to hear about.

Exactly, I’m using sentry in some prototypes and transitioned into using Julia

1 Like

Hi @pengwyn, I’m really glad to see that there is a Julia package for sentry. Definitely going to take a look at the repo. Any particular status updates?