Core Java

5 Error Tracking Tools Java Developers Should Know

Raygun, Stack Hunter, Sentry, Takipi and Airbrake: Modern developer tools to help you crush bugs before bugs crush your app! 

Bug-line

With the Java ecosystem going forward, web applications serving growing numbers of requests and users’ demand for high performance – comes a new breed of modern development tools. A fast paced environment with rapid new deployments requires tracking errors and gaining insight to an application’s behavior on a level traditional methods can’t sustain. In this post we’ve decided to gather 5 of those tools, see how they integrate with Java and find out what kind of tricks they have up their sleeves. It’s time to smash some bugs.

Raygun

Mindscape’s Raygun is a web based error management system that keeps track of exceptions coming from your apps. It supports various desktop, mobile and web programming languages, including Java, Scala, .NET, Python, PHP, and JavaScript. Besides that, sending errors to Raygun is possible through a REST API and a few more Providers (that’s how they call language and framework integrations) came to life thanks to developer community involvement.

Raygun-screenshots

Key Features:

  • Error grouping – Every occurrence of a bug is presented within one group with access to single instances of it, including its stack trace.
  • Full text search – Error groups and all collected data is searchable.
  • View app activity – Every action on an error group is displayed for all your team to see: status updates, comments and more.
  • Affected users – Counts of affected users appear by each error.
  • External integrations – Github, Bitbucket, Asana, JIRA, HipChat and many more.

The Java angle: To use Raygun with Java, you’ll need to add some dependencies to your pom.xml file if you’re using Maven or add the jars manually. The second step would be to add an UncaughtExceptionHandler that would create an instance of RaygunClient and send your exceptions to it. In addition, you can also add custom data fields to your exceptions and send them together to Raygun. The full walkthrough is available here.

Behind the curtain: Meet Robie Robot, the certified operator of Raygun. As in, the actual ray gun.

Check it out on: https://raygun.io

Sentry

Started as a side-project, Sentry is an open-source web based solution that serves as a real time event logging and aggregation platform. It monitors errors and displays when, where and to whom they happen, promising to do so without relying solely on user feedback. Supported languages and frameworks include Ruby, Python, JS, Java, Django, iOS, .NET and more.

Sentry-screenshot1

Key Features:

  • See the impact of new deployments in real time
  • Provide support to specific users interrupted by an error
  • Detect and thwart fraud as its attempted – notifications of unusual amounts of failures on purchases, authentication, and other sensitive areas
  • External Integrations – GitHub, HipChat, Heroku, and many more

The Java angle: Sentry’s Java client is called Raven and supports major existing logging frameworks like java.util.logging, Log4j, Log4j2 and Logback with Slf4j. An independent method to send events directly to Sentry is also available. To set up Sentry for Java with Logback for example, you’ll need to add the dependencies manually or through Maven, then add a new Sentry appender configuration and you’re good to do. Instructions are available here.

Behind the curtain: Sentry was an internal project at Disqus back in 2010 to solve exception logging on a Django application by Chris Jennings and David Cramer

Check it out on: https://www.getsentry.com/

Takipi

Unlike most of the other tools, Takipi is far more than a stack trace prettifier. It was built with a simple objective in mind: Telling developers exactly when and why production code breaks. Whenever a new exception is thrown or a log error occurs – Takipi captures it and shows you the variable state which caused it, across methods and machines. Takipi will overlay this over the actual code which executed at the moment of error – so you can analyze the exception as if you were there when it happened.

Takipi2

Key features:

  • Detect – Caught/uncaught exceptions, Http and logged errors.
  • Prioritize – How often errors happen across your cluster, if they involve new or modified code, and whether that rate is increasing.
  • Analyze – See the actual code and variable state, even across different machines and applications.
  • Easy to install – No code or configuration changes needed.
  • Less than 2% overhead.

The Java angle: Takipi was built for production environments in Java and Scala. The installation takes less than 1min, and includes attaching a Java agent to your JVM.

Behind the curtain: Each exception type and error has a unique monster that represents it. You can find these monster here.

Check it out on: http://www.takipi.com/

Airbrake

Airbrake-screenshots

Another tool that has put exception tracking on its eyesights is Rackspace’s Airbrake, taking on the mission of “No More Searching Log Files”. It provides users with a web based interface that includes a dashboard with error details and an application specific view. Supported languages include Ruby, PHP, Java, .NET, Python and even… Swift.

Key Features:

  • Detailed stack traces, grouping by error type, users and environment variables
  • Team productivity – Filter importance errors from the noise
  • Team collaboration – See who’s causing bugs and whose fixing them
  • External Integrations – HipChat, GitHub, JIRA, Pivotal and over 30 more

The Java angle: Airbrake officially supports only Log4j, although a Logback library is also available. Log4j2 support is currently lacking. The installation procedure is similar to Sentry, adding a few dependencies manually or through Maven, adding an appender, and you’re ready to start. Similarly, a direct way to send messages to Airbrake is also available with AirbrakeNotice and AirbrakeNotifier. More details are available here.

Behind the curtain: Airbrake was acquired by Exceptional, which then got acquired by Rackspace.

Check it out on: https://airbrake.io/

StackHunter

Currently in beta, Stack Hunter provides a self hosted tool to track your Java exceptions. A change of scenery from the past hosted tools. Other than that, it aims to provide a similar feature set to inform developers of their exceptions and help solve them faster.

StackHunter-screenshot

Key Features:

  • A single self hosted web interface to view all exceptions
  • Collections of stack trace data and context including key metrics such as total exceptions, unique exceptions, users affected, & sessions affected
  • Instant email alerts when exceptions occur
  • Exceptions grouping by root cause

The Java angle: Built specifically for Java, StackHunter runs on any servlet container running Java 6 or above. Installation includes running StackHunter on a local servlet, configuring an outgoing mail server for alerts, and configuring the application you’re wishing to log. Full instructions are available here.

Behind the curtain: StackHunter is developed by Dele Taylor, who also works on Data Pipeline – a tool for transforming and migrating data in Java.

Check it out on: http://stackhunter.com/

Bonus: ABRT

Another approach to error tracking worth mentioning is used by ABRT, an automatic bug detection and reporting tool from the Fedora ecosystem, which is a Red Hat sponsored community project. Unlike the 5 tools we covered here, this one is intended to be used not only by app developers – but their users as well. Reporting bugs back to Red Hat with richer context that otherwise would have been harder to understand and debug.

ABRT

The Java angle: Support for Java exceptions is still in its proof of concept stage. A Java connector developed by Jakub Filák is available here.

Behind the curtain: ABRT is an open-source project developed by Red Hat.

Check it out on: https://github.com/abrt/abrt

Did we miss any other tools? How do you keep track of your exceptions? Please let me know in the comments section below

Reference: 5 Error Tracking Tools Java Developers Should Know from our JCG partner Alex Zhitnitsky at the Takipi blog.

Alex Zhitnitsky

Alex is an engineer working with OverOps on a mission to help Java and Scala developers solve bugs in production and rid the world of buggy software. Passionate about all things tech, he is also the co-founder & lead of GDG Haifa, a local developer group. Alex holds a B.Sc from the Technion, Israel's Institute of Technology.
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

4 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
dumbo
dumbo
10 years ago

free alternative: http://squash.io/ coming from square inc.

Tom Henricksen
10 years ago

Has anyone used these in production environment? I have played with Takipi but not in a production environment. I guess I will have to look at the others and see what works best for me.

Anuj
Anuj
10 years ago

I am planning to use Sentry ! Looks good actually.

Mike Smith
9 years ago

I’m biased but I think https://rollbar.com deserves honorable mention. :)

Back to top button