Heroku 🔗
The Splunk OpenTelemetry Connector for Heroku is a buildpack for the Splunk Distribution of the OpenTelemetry Collector. The buildpack installs and runs the Splunk OpenTelemetry Connector on a Dyno to receive, process and export metric and trace data for Splunk Observability Cloud:
Splunk APM through the
sapm
exporter. Theotlphttp
exporter can be used with a custom configuration.Splunk Infrastructure Monitoring through the
signalfx
exporter.
See Get started with the Splunk Distribution of the OpenTelemetry Collector to learn more.
Prerequisites 🔗
Before you can install the Heroku buildpack to collect metrics, you need to have a Heroku app. To learn how to install the Heroku CLI and create an app, see the Heroku documentation for developers.
Installation steps 🔗
Follow these steps to collect metrics with the Heroku buildpack for the Splunk Distribution of the OpenTelemetry Collector:
In the command-line interface, navigate to the Heroku project directory.
cd <HEROKU_APP_DIRECTORY>
Note: Running
heroku
command outside of project directories results in unexpected behavior.Configure the Heroku app to expose Dyno metadata, which is required by Splunk OpenTelemetry Connector to set global dimensions such as
app_name
,app_id
anddyno_id
. See here for more information.heroku labs:enable runtime-dyno-metadata
Run both of the following commands together to add the Heroku buildpack.
heroku buildpacks:add https://github.com/signalfx/splunk-otel-collector-heroku.git#\ $(curl -s https://api.github.com/repos/signalfx/splunk-otel-collector-heroku/releases | grep '"tag_name"' | head -n 1 | cut -d'"' -f4)
Note: If you want to use an explict version number for production environment, replace the first command with the following command:
heroku buildpacks:add https://github.com/signalfx/splunk-otel-collector-heroku.git#<TAG_NAME>
Set the required environment variables.
heroku config:set SPLUNK_ACCESS_TOKEN=<YOUR_ACCESS_TOKEN> heroku config:set SPLUNK_REALM=<YOUR_REALM>
(Optional) Define custom configuration file in your Heroku project directory.
heroku config:set SPLUNK_CONFIG=/app/mydir/myconfig.yaml
To add the buildpack to an existing project, you must create an empty commit before deploying the app.
git commit --allow-empty -m "empty commit"
Run the following command to deploy the app.
git push heroku main
Run the following command to check the logs.
heroku logs -a <app-name> --tail
Configuration 🔗
Use the following environment variables to configure the Heroku buildpack.
Environment Variable |
Required |
Default |
Description |
---|---|---|---|
|
Yes |
Splunk access token. |
|
|
Yes |
Splunk realm |
|
|
No |
|
The Splunk API base URL. |
|
No |
|
|
|
No |
|
The Splunk Infrastructure Monitoring base URL. |
|
No |
|
|
|
No |
|
Total available memory to agent. |
|
No |
|
Version of Splunk OTel Connector to use. Defaults to latest. |
|
No |
|
The Splunk APM base URL. |
Troubleshooting 🔗
If you are a Splunk Observability Cloud customer and are not able to see your data in Splunk Observability Cloud, you can get help in the following ways.
Available to Splunk Observability Cloud customers
Submit a case in the Splunk Support Portal .
Contact Splunk Support .
Available to prospective customers and free trial users
Ask a question and get answers through community support at Splunk Answers .
Join the Splunk #observability user group Slack channel to communicate with customers, partners, and Splunk employees worldwide. To join, see Chat groups in the Get Started with Splunk Community manual.