Before you start
Before you can start using the alerts, make sure to install the dbt package, configure a profile and install the CLI. This is required for the alerts to work.
First create a Slack app:
Create a Slack App
Go to the Slack page to create apps and create a new app (from scratch). Call it "Elementary" and connect it to the workspace of your choice.
To change the display of the Elementary slack app, scroll down on the Slack app basic information page to the 'Display Information' section:
Here is the Elementary icon for your use (click to download):
Based on the method you selected, create a token or webhook:
Create Slack Token
Go to the "OAauth & Permissions" page for your newly-created app, and add the following scopes under "Bot Token Scopes":
channels:join
- Join public channels in a workspacechannels:read
- View basic information about public channels in a workspacechat:write
- Send messages as <app>files:write
- Upload, edit, and delete files as <app>users:read
- View people in a workspaceusers:read.email
- View email addresses of people in a workspacegroups:read
- View basic information about private channels that your slack app has been added toAt the "OAuth & Permissions" page, press on "Install to Workspace" in order to generate Slack token:
Create Slack Webhook
Go to the 'Incoming Webhooks' page for your newly-created app and toggle 'Activate Incoming Webhooks' to turn it on. Then click on 'Add New Webhook to Workspace':
Select the channel that the notifications will be posted to:
Lastly, pass the token / webhook to the CLI as a param or in the config.yml
file:
Slack config as CLI params
Slack config as in config.yml
Make sure to run the following command after your dbt runs and tests:
Or just edr monitor
if you used config.yml
. Please note that when you specify the —slack-channel-name, it’s the
default channel name to which all the alerts will be sent that are not attributed to any custom channel. Therefore,
if you execute several edr monitor
commands at the same time with different slack-channel-name
arguments, they can
be sent to the wrong one due to the overlap accessing the backend table of elementary. For avoiding this problem,
the guide can be followed.
Not supported in dbt cloud
To alert on source freshness, you will need to run edr run-operation upload-source-freshness
right after each execution of dbt source freshness
.
This operation will upload the results to a table, and the execution of edr monitor
will send the actual alert.
dbt source freshness
and upload-source-freshness
needs to run from the same machine.upload-source-freshness
requires passing --project-dir
argument.In order to monitor continuously, use your orchestrator to execute it regularly (we recommend running it right after your dbt job ends to monitor the latest data updates).
Read more about how to deploy Elementary in production. If you need help or wish to consult on this, reach out to us on Slack.
Before you start
Before you can start using the alerts, make sure to install the dbt package, configure a profile and install the CLI. This is required for the alerts to work.
First create a Slack app:
Create a Slack App
Go to the Slack page to create apps and create a new app (from scratch). Call it "Elementary" and connect it to the workspace of your choice.
To change the display of the Elementary slack app, scroll down on the Slack app basic information page to the 'Display Information' section:
Here is the Elementary icon for your use (click to download):
Based on the method you selected, create a token or webhook:
Create Slack Token
Go to the "OAauth & Permissions" page for your newly-created app, and add the following scopes under "Bot Token Scopes":
channels:join
- Join public channels in a workspacechannels:read
- View basic information about public channels in a workspacechat:write
- Send messages as <app>files:write
- Upload, edit, and delete files as <app>users:read
- View people in a workspaceusers:read.email
- View email addresses of people in a workspacegroups:read
- View basic information about private channels that your slack app has been added toAt the "OAuth & Permissions" page, press on "Install to Workspace" in order to generate Slack token:
Create Slack Webhook
Go to the 'Incoming Webhooks' page for your newly-created app and toggle 'Activate Incoming Webhooks' to turn it on. Then click on 'Add New Webhook to Workspace':
Select the channel that the notifications will be posted to:
Lastly, pass the token / webhook to the CLI as a param or in the config.yml
file:
Slack config as CLI params
Slack config as in config.yml
Make sure to run the following command after your dbt runs and tests:
Or just edr monitor
if you used config.yml
. Please note that when you specify the —slack-channel-name, it’s the
default channel name to which all the alerts will be sent that are not attributed to any custom channel. Therefore,
if you execute several edr monitor
commands at the same time with different slack-channel-name
arguments, they can
be sent to the wrong one due to the overlap accessing the backend table of elementary. For avoiding this problem,
the guide can be followed.
Not supported in dbt cloud
To alert on source freshness, you will need to run edr run-operation upload-source-freshness
right after each execution of dbt source freshness
.
This operation will upload the results to a table, and the execution of edr monitor
will send the actual alert.
dbt source freshness
and upload-source-freshness
needs to run from the same machine.upload-source-freshness
requires passing --project-dir
argument.In order to monitor continuously, use your orchestrator to execute it regularly (we recommend running it right after your dbt job ends to monitor the latest data updates).
Read more about how to deploy Elementary in production. If you need help or wish to consult on this, reach out to us on Slack.