Skip to main content
Grafana Alloy is Grafana’s distribution of the OpenTelemetry Collector. It forwards logs, metrics, and traces to Bronto with the otelcol.exporter.otlphttp component. This page covers Alloy configuration only. For installation instructions, see the Alloy installation guide.

Endpoint and authentication

Set the exporter’s endpoint to the base ingestion URL for your Bronto region. Alloy appends /v1/logs, /v1/metrics, and /v1/traces for each signal. Bronto uses the service.name and service.namespace resource attributes to pick the dataset and collection for logs. Only the API key header is required:
Datasets and collections apply only to logs. Metrics appear in the Metric Explorer, and traces appear in Explore Traces.

Logs, metrics, and traces

The example below sends all three signals through one exporter:
  • Logs — tails files with loki.source.file, converts the entries to OTLP with otelcol.receiver.loki, and sets the dataset and collection.
  • Metrics — collects host metrics with prometheus.exporter.unix and converts Prometheus counters from cumulative to delta.
  • Traces — accepts OTLP from your instrumented applications on ports 4317 (gRPC) and 4318 (HTTP).
config.alloy
Start Alloy with the API key in its environment:
The metrics pipeline needs a lowered stability level. honor_metadata on prometheus.scrape is experimental, and otelcol.processor.cumulativetodelta is public preview. If you don’t send metrics, remove the metrics components and drop the flag. The logs and traces components here are generally available.

Why the transform processor is needed

otelcol.receiver.loki turns Loki labels such as job and filename into log record attributes, not resource attributes. Without the otelcol.processor.transform step, the logs have no service.name or service.namespace, so Bronto can’t route them to the dataset and collection you expect. Alternatively, set the x-bronto-dataset and x-bronto-collection headers on the exporter. Use a separate exporter for logs if you do, because headers apply to every signal the exporter sends.

Why honor_metadata is needed

By default, prometheus.scrape doesn’t pass metric type metadata downstream. otelcol.receiver.prometheus then can’t tell a counter from a gauge, so every metric reaches Bronto as a gauge. For example, node_cpu_seconds_total arrives as an ever-growing gauge instead of a counter, and each histogram is split into separate _bucket, _sum, and _count gauges. honor_metadata = true keeps the counter, histogram, and summary types. If you can’t run Alloy with --stability.level=experimental, remove honor_metadata. Metrics still arrive, but only as gauges, and otelcol.processor.cumulativetodelta has nothing to convert.

Why metrics are converted to delta

Prometheus counters and histograms are cumulative. Bronto accepts cumulative sums and histograms, but delta is strongly recommended to get the best value from the current set of supported functions. See Send Metrics to Bronto for the supported metric types.

Send only the signals you need

Each pipeline is independent. To send a subset of signals, remove the components you don’t need and the matching entries in each output block.

Already using Loki or Prometheus pipelines

If Alloy already sends to Loki or Prometheus, you don’t need to change your sources. Add Bronto as a second destination:
  • Loki logs — add otelcol.receiver.loki.default.receiver to the forward_to list of your existing loki.source.* or loki.process components.
  • Prometheus metrics — add otelcol.receiver.prometheus.default.receiver to the forward_to list of your existing prometheus.scrape components, and set honor_metadata = true on them.

Tail files with the OpenTelemetry filelog receiver

Instead of the Loki components, you can tail files with otelcol.receiver.filelog, which sets resource attributes directly and needs no transform step. It is also a public preview component.
config.alloy

Kubernetes

On Kubernetes, run Alloy as a DaemonSet with the Grafana Alloy Helm chart. Each Alloy pod tails the container logs on its own node from /var/log/pods. Logs from each container go to their own dataset, and the cluster is the collection. Create a secret for the API key, then install the chart:
values.yaml
The configuration:
  • Discovers only the pods on the same node, using the NODE_NAME environment variable.
  • Strips the container runtime prefix from each line with stage.cri, so Bronto receives the original log line.
  • Starts at the end of existing log files (tail_from_end = true) rather than sending each container’s full log history when Alloy starts.
  • Sets service.name to the container name and adds k8s.namespace.name and k8s.pod.name, so you can filter by namespace and pod in Bronto.
otelcol.receiver.loki sends each log line downstream on its own. Without otelcol.processor.batch, a busy node fills the exporter’s sending queue and Alloy logs sending queue is full errors and drops logs.

Parsing unstructured logs

Rather than parsing in Alloy, ship raw log lines to Bronto and use the Bronto Custom Parser to extract structured fields server-side.

Verify delivery

Once Alloy is running:
  • Logs appear in Search under the dataset you set.
  • Metrics appear in the Metric Explorer. With initial_value = "drop", the first scrape of each series is used as a baseline, so metrics start arriving after the second scrape.
  • Traces appear in Explore Traces.
To check component health, open the Alloy UI at http://localhost:12345. A 401 error from otelcol.exporter.otlphttp.bronto in the Alloy logs means the API key is missing or invalid.

Further reading