steampipe plugin install sentry

Table: sentry_issue_alert - Query Sentry Issue Alerts using SQL

Sentry is an open-source application monitoring platform that helps uncover, triage, and prioritize errors in real-time. An Issue Alert in Sentry is a notification sent when certain conditions are met in a project, such as when an event occurs that matches the conditions defined in an alert rule. These alerts help to identify and manage issues in your applications and infrastructure.

Table Usage Guide

The sentry_issue_alert table provides insights into Issue Alerts within Sentry's application monitoring platform. As a developer or DevOps engineer, explore alert-specific details through this table, including alert rules, projects, and associated metadata. Utilize it to uncover information about alerts, such as those related to specific projects or rules, helping you to triage and prioritize errors in your applications effectively.

Examples

Basic info

Explore which issues have triggered alerts in your Sentry application. This can help in identifying potential problematic areas, allowing for timely intervention and issue resolution.

select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert;
select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert;

List alerts for a particular project

Explore the alerts associated with a specific project to gain insights into issues that may need immediate attention. This can help in assessing the health and stability of the project.

select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert
where
project_slug = 'go';
select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert
where
project_slug = 'go';

List alerts owned by a particular team

Determine the areas in which specific alerts are owned by a certain team. This can help in understanding the distribution of responsibility and tracking the issues that a particular team needs to address.

select
a.id,
a.name,
a.owner,
a.organization_slug,
a.project_slug,
a.action_match,
a.date_created
from
sentry_issue_alert as a,
sentry_team as t
where
t.id = split_part(a.owner, ':', 2)
and t.name = 'Team A';
Error: SQLite does not support split_part function.

Show list of actions of a particular alert

Explore the actions associated with a specific alert to gain insights into its configuration and owner details. This can be useful for understanding the alert's role and impact within a project.

select
id,
name,
owner,
project_slug,
jsonb_pretty(actions) as actions
from
sentry_issue_alert
where
name = 'alert1';
select
id,
name,
owner,
project_slug,
actions
from
sentry_issue_alert
where
name = 'alert1';

List alerts older than a month

Analyze the settings to understand any alerts that have been active for over a month. This can help in identifying long-standing issues that may require immediate attention or escalation.

select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert
where
date_created <= now() - interval '1 month';
select
id,
name,
owner,
organization_slug,
project_slug,
action_match,
date_created
from
sentry_issue_alert
where
date_created <= datetime('now', '-1 month');

Schema for sentry_issue_alert

NameTypeOperatorsDescription
_ctxjsonbSteampipe context in JSON form.
action_matchtextTrigger actions when an event is captured by Sentry and any or all of the specified conditions happen.
actionsjsonbList of actions.
conditionsjsonbList of conditions.
created_byjsonbThe rule creator who created the issue alert.
date_createdtimestamp with time zoneThe creation timestamp of the issue alert.
environmenttextPerform issue alert in a specific environment.
filter_matchtextTrigger actions if all, any, or none of the specified filters match.
filtersjsonbList of filters.
frequencybigintPerform actions at most once every X minutes for this issue. Defaults to 30.
idtext=The ID of the issue alert.
nametextThe issue alert name.
organization_slugtext=The slug of the organization the issue alert belongs to.
ownertextThe owner of the issue alert.
project_slugtext=The slug of the project the issue alert belongs to.
projectsjsonbThe projects for which the issue alert is created.
sp_connection_nametext=, !=, ~~, ~~*, !~~, !~~*Steampipe connection name.
sp_ctxjsonbSteampipe context in JSON form.
task_uuidtextThe UUID of the async task that can be spawned to create the issue alert.
titletextTitle of the resource.

Export

This table is available as a standalone Exporter CLI. Steampipe exporters are stand-alone binaries that allow you to extract data using Steampipe plugins without a database.

You can download the tarball for your platform from the Releases page, but it is simplest to install them with the steampipe_export_installer.sh script:

/bin/sh -c "$(curl -fsSL https://steampipe.io/install/export.sh)" -- sentry

You can pass the configuration to the command with the --config argument:

steampipe_export_sentry --config '<your_config>' sentry_issue_alert