Skip to main content

Rollbar

CatalogScorecards

Rollbar is an error tracking tool that helps developers discover and resolve crashes and errors. By integrating Rollbar with Cortex, you can motivate team members to improve code quality and drive insights into error tracking, error rates, and exceptions.

Setup and configuration

Getting started

In order to connect Cortex to your Rollbar instance, you’ll first need to create a Rollbar access token.

The token requires read permissions at a minimum - this allows Cortex to automatically look up project tokens for each Rollbar project and attempt to reuse them to access project details.

Granting the token read and write permissions enables Cortex to automatically create an access token if none exists for a given project.

caution

If you do not see the settings page you're looking for, you likely don't have the proper permissions and need to contact your admin.

Configuration

Once you've created the access token, add it under Rollbar settings in Cortex.

  • Account access token: Access token you created in Rollbar.
  • Account name: Name for your Rollbar account, found in settings. The account name is also in the URL for your Rollbar instance - https://rollbar.com/{SLUG}/.

If you’ve set everything up correctly, you’ll see the option to Remove Integration in settings.

You can also use the Test configuration button to confirm that the configuration was successful. If your configuration is valid, you’ll see a banner that says “Configuration is valid. If you see issues, please see documentation or reach out to Cortex support.”

Registration

Discovery

By default, Cortex will use the entity tag (e.g. my-entity) as the "best guess" for Rollbar project name. For example, if your entity tag is my-entity, then the corresponding project name in Rollbar should also be my-entity.

If your Rollbar project name don’t cleanly match the Cortex entity tag, you can override this in the Cortex entity descriptor.

Entity descriptor

If you need to override automatic discovery, you can define the following block in your Cortex entity descriptor.

x-cortex-rollbar:
project: my-project
FieldDescriptionRequired
projectProject name as defined in Rollbar

Expected results

Entity pages

Integrations - Rollbar

You can access detailed information from Rollbar in the Rollbar tab under Integrations in the sidebar. At the top of the page, you'll find the associated project tag and the project framework.

Under Items, you'll find a list of detected errors and their statuses (e.g. "active"). Next to the error name, you'll also see badges for # seen and the type of event: error, warning, or info.

Scorecards and CQL

With the Rollbar integration, you can create Scorecard rules and write CQL queries based on Rollbar projects.

See more examples in the CQL Explorer in Cortex.

Check if Rollbar project is set

Check if entity has a registered Rollbar project.

Definition: rollbar (==/!=) null

Example

You can define a rule in an operational readiness Scorecard to make sure each entity has a registered Rollbar project.

rollbar != null

This is also a good way to confirm the integration is synced and reporting frequently.

You could also query for entities that don't have a registered Rollbar project to quickly identify those that need to be updated:

rollbar == null
RQL query

Evaluate an RQL query for the Rollbar project.

If the entity does not have a Rollbar project set, the rule will fail. An empty result set will result in null.

Definition: rollbar.rql(<query>)

Examples

An operational maturity Scorecard, you can use this expression to make sure entities have fewer than 100 open errors.

rollbar.rql("SELECT count(*) FROM item_occurrence WHERE status = 1") < 100

Or you can set a rule that gauges errors over time:

rollbar.rql("SELECT count(*) / 30 FROM item_occurrence WHERE timestamp > unix_timestamp() - 60 * 60 * 24 * 30") < 5

This rule checks that entities have fewer than 5 new errors per day on average over the last 30 days.

Still need help?

The following are all the ways to get assistance from our customer engineering team. Please use the option that is best for your users:

  • Email: help@cortex.io, or open a support ticket in the in app Resource Center
  • Chat: Available in the Resource Center
  • Slack: Users with a connected Slack channel will have a workflow added to their account. From here, you can either @CortexTechnicalSupport or add a :ticket: reaction to a question in Slack, and the team will respond directly.

Don’t have a Slack channel? Talk with your customer success manager.