Honeycomb
Artillery provides comprehensive integration with Honeycomb through both native support and OpenTelemetry protocol.
Quick Start
Native Integration
plugins:
publish-metrics:
- type: honeycomb
apiKey: '{{ $env.HONEYCOMB_API_KEY }}'
dataset: 'My-Load-Test'Configuration Methods
Native Integration
The native Honeycomb reporter enables you to send traces to Honeycomb . Sending traces to Honeycomb is supported for both HTTP and Playwright engines, and the tracing data available is different depending on the engine used.
An additional plugins.publish-metrics.spans.exported metric will be recorded and will appear in your reports when tracing is enabled. It represents the number of spans exported to Honeycomb.
Configuration Options
| Name | Description |
|---|---|
apiKey (required) | Your Honeycomb API key |
dataset (required) | Name of a dataset you want to send traces to |
useRequestNames Added inv2.0.5 | If set to true the request names provided in test script will be used as span names |
sampleRate | Sample rate. Percentage of traces to send represented by a value between 0 and 1. (defaults to 1 - all traces are sent) |
attributes Added inv2.0.5 | Custom attributes in key: value pair format to be added to each span |
enabled | Set to false to disable the reporter |
replaceSpanNameRegex Added inv2.0.9 | A list of replacement maps that consist of:pattern - regex pattern to match against the span names as - string to replace the matched pattern in the span names |
Example
config:
plugins:
publish-metrics:
- type: honeycomb
apiKey: '{{ $env.HONEYCOMB_API_KEY }}'
dataset: 'My-Load-Test'
sampleRate: 0.5
replaceSpanNameRegex:
- pattern: get_user_[a-zA-Z0-9]+
as: get_user_id
attributes:
testType: LoadTest
tool: ArtilleryOpenTelemetry Integration
You can also send both metrics and traces to Honeycomb using OpenTelemetry protocol.
Requirements
- API key
- OTLP Endpoints (already provided below)
Configuration
plugins:
publish-metrics:
- type: open-telemetry
serviceName: <your_service_name>
traces:
endpoint: https://api.honeycomb.io/v1/traces
headers:
x-honeycomb-team: '{{ $env.HONEYCOMB_API_KEY }}'
metrics:
endpoint: https://api.honeycomb.io/v1/metrics
headers:
x-honeycomb-team: '{{ $env.HONEYCOMB_API_KEY }}'
x-honeycomb-dataset: <your_dataset_name>NOTE: x-honeycomb-dataset needs to be set for metrics. We advise setting
it to the same as your serviceName so that metrics and traces are
grouped under the same dataset (namespace).
Examples
Complete Native Integration
config:
plugins:
publish-metrics:
- type: honeycomb
apiKey: '{{ $env.HONEYCOMB_API_KEY }}'
dataset: 'production-load-tests'
sampleRate: 0.1
useRequestNames: true
attributes:
environment: production
testType: LoadTest
version: '{{ $env.APP_VERSION }}'OpenTelemetry with Full Features
plugins:
publish-metrics:
- type: open-telemetry
serviceName: my-service
resourceAttributes:
environment: production
traces:
endpoint: https://api.honeycomb.io/v1/traces
headers:
x-honeycomb-team: '{{ $env.HONEYCOMB_API_KEY }}'
sampleRate: 0.1
attributes:
test.id: '{{ $testId }}'
metrics:
endpoint: https://api.honeycomb.io/v1/metrics
headers:
x-honeycomb-team: '{{ $env.HONEYCOMB_API_KEY }}'
x-honeycomb-dataset: my-service
includeOnly:
- http.response_time
- http.requests
- errors.countDebugging
Set DEBUG=plugin:publish-metrics:honeycomb when running your tests to print out helpful debugging messages when sending metrics to Honeycomb.
DEBUG=plugin:publish-metrics:honeycomb artillery run my-script.yamlReference
For additional information about OpenTelemetry data in Honeycomb consult Honeycomb’s documentation .