OpenTelemetry Collector deployment, instrumentation (Java/Python/Node.js/.NET/Go), and OTTL pipeline transforms for Coralogix — coralogix exporter config, Helm chart selection, Kubernetes topology, ECS/EKS/GKE deployments, SDK setup, APM transactions, and OTTL cardinality/PII/routing.
98
97%
Does it follow best practices?
Impact
99%
1.13xAverage score across 81 eval scenarios
Advisory
Suggest reviewing before use
Source: Coralogix Node.js OpenTelemetry Instrumentation documentation.
The Coralogix Node.js SDK (coralogix-logger, @coralogix/coralogix-sdk) and the
Coralogix Winston and Bunyan integrations are deprecated and reach end-of-life on
June 30, 2026. The official Coralogix Node.js SDK docs page has already been rewritten
to show OpenTelemetry as the replacement. If a user asks about coralogix-logger, the
Coralogix Winston integration, or the Coralogix Bunyan integration, redirect them to OTel
Node.js instrumentation immediately. Do not explain how to configure the deprecated packages.
See: https://coralogix.com/docs/user-guides/latest-updates/deprecations/
^18.19.0 || >=20.6.0 (required by OTel JS SDK 2.x — Node 14/16 are not supported)Node.js supports three approaches:
NODE_OPTIONS.instrumentation.js with chosen libraries.BasicTracerProvider + span creation.Coralogix transactions caveat: Bundled auto-instrumentation is NOT supported for
Coralogix transactions (APM → Transactions view). Use individual auto-instrumentation or
manual instrumentation to enable CoralogixTransactionSampler.
Use the official OpenTelemetry Node.js getting-started guide for SDK installation: https://opentelemetry.io/docs/languages/js/getting-started/nodejs/
For Coralogix APM Transactions, include @coralogix/opentelemetry in the same dependency
management flow.
Set environment variables and use NODE_OPTIONS to load the registration library:
export OTEL_TRACES_EXPORTER="otlp"
export OTEL_EXPORTER_OTLP_PROTOCOL="grpc"
export OTEL_EXPORTER_OTLP_COMPRESSION="gzip"
# gRPC endpoint: bare host:port is the standard Coralogix form; https://host:port is also accepted
export OTEL_EXPORTER_OTLP_ENDPOINT="ingress.<CORALOGIX_REGION>.coralogix.com:443"
export OTEL_EXPORTER_OTLP_HEADERS="Authorization=Bearer <CORALOGIX_API_KEY>"
export OTEL_NODE_RESOURCE_DETECTORS="all"
export OTEL_SERVICE_NAME="<SERVICE_NAME>"
export OTEL_RESOURCE_ATTRIBUTES="cx.application.name=<CX_APPLICATION_NAME>,cx.subsystem.name=<CX_SUBSYSTEM_NAME>"
node --require @opentelemetry/auto-instrumentations-node/register YourApp.jsOr using NODE_OPTIONS:
export NODE_OPTIONS="--require @opentelemetry/auto-instrumentations-node/register"
node YourApp.jsReminder: Env vars cannot be set inside the application code — they must be available before the auto-instrumentation library starts at process startup.
Limitation: Bundled auto-instrumentation does NOT support Coralogix transactions. Switch to individual method below if transactions are needed.
ESM apps (using import syntax): --require does not fire for ES modules — auto-instrumentation silently does nothing. Use --import plus the loader hook instead:
node --experimental-loader=@opentelemetry/instrumentation/hook.mjs \
--import @opentelemetry/auto-instrumentations-node/register YourApp.mjsCreate an instrumentation.js file:
// instrumentation.js
const { HttpInstrumentation } = require('@opentelemetry/instrumentation-http');
const { ExpressInstrumentation } = require('@opentelemetry/instrumentation-express');
const opentelemetry = require("@opentelemetry/sdk-node");
const { CoralogixTransactionSampler } = require("@coralogix/opentelemetry");
const { AlwaysOnSampler } = require("@opentelemetry/sdk-trace-base");
// Exporter is configured via env vars (OTEL_TRACES_EXPORTER, OTEL_EXPORTER_OTLP_PROTOCOL,
// OTEL_EXPORTER_OTLP_ENDPOINT, OTEL_EXPORTER_OTLP_HEADERS) — same as the bundled approach.
const sdk = new opentelemetry.NodeSDK({
sampler: new CoralogixTransactionSampler(new AlwaysOnSampler()),
instrumentations: [
new HttpInstrumentation(),
new ExpressInstrumentation(),
// add more individual instrumentation libraries as needed
],
});
sdk.start();Use the same environment variables as bundled (above), then run:
node --require ./instrumentation.js YourApp.jsThis approach allows CoralogixTransactionSampler to be wired into the sampler chain,
enabling Coralogix Transactions support.
Full manual control over span creation using NodeTracerProvider:
const opentelemetry = require('@opentelemetry/api');
const { resourceFromAttributes } = require('@opentelemetry/resources');
const { ATTR_SERVICE_NAME } = require('@opentelemetry/semantic-conventions');
const { NodeTracerProvider } = require('@opentelemetry/sdk-trace-node');
const { SimpleSpanProcessor, AlwaysOnSampler } = require('@opentelemetry/sdk-trace-base');
const { OTLPTraceExporter } = require("@opentelemetry/exporter-trace-otlp-proto");
const { CoralogixTransactionSampler } = require('@coralogix/opentelemetry');
const exporter = new OTLPTraceExporter({
timeoutMillis: 15000,
// HTTP/proto exporter requires /v1/traces path
url: 'https://ingress.<CORALOGIX_REGION>.coralogix.com:443/v1/traces',
headers: {
Authorization: `Bearer ${process.env.CORALOGIX_API_KEY}`,
},
});
const provider = new NodeTracerProvider({
resource: resourceFromAttributes({
[ATTR_SERVICE_NAME]: '<SERVICE_NAME>',
'cx.application.name': '<CX_APPLICATION_NAME>',
'cx.subsystem.name': '<CX_SUBSYSTEM_NAME>',
}),
sampler: new CoralogixTransactionSampler(new AlwaysOnSampler()),
spanProcessors: [new SimpleSpanProcessor(exporter)],
});
provider.register();
// Graceful shutdown
['SIGINT', 'SIGTERM'].forEach(signal => {
process.on(signal, () => provider.shutdown().catch(console.error));
});
const tracer = opentelemetry.trace.getTracer('<SERVICE_NAME>');
const span = tracer.startSpan('main');
// ... do work ...
span.end();Name these package artifacts when explaining the manual setup, but use the official OpenTelemetry Node.js getting-started guide for installation details and current versions:
@opentelemetry/api@opentelemetry/exporter-trace-otlp-proto@opentelemetry/resources@opentelemetry/sdk-trace-base@opentelemetry/sdk-trace-node@coralogix/opentelemetryconst { logs, SeverityNumber } = require('@opentelemetry/api-logs');
const { LoggerProvider, SimpleLogRecordProcessor } = require('@opentelemetry/sdk-logs');
const loggerProvider = new LoggerProvider({
processors: [new SimpleLogRecordProcessor(/* add OTLP exporter here */)],
});
logs.setGlobalLoggerProvider(loggerProvider);
const logger = logs.getLogger('my-logger', '1.0.0');
const error = new Error('database connection failed');
logger.emit({
severityNumber: SeverityNumber.ERROR,
severityText: 'ERROR',
body: 'request failed',
exception: error,
});Exception support requires @opentelemetry/api-logs and @opentelemetry/sdk-logs >= 0.212.0.
The OpenTelemetry Operator supports Node.js auto-instrumentation injection:
annotations:
instrumentation.opentelemetry.io/inject-nodejs: "true"OTel Node.js propagates W3C traceparent headers automatically on outgoing HTTP requests
via @opentelemetry/instrumentation-http. To verify propagation is working:
traceparent in outgoing request headers in the outputtraceparentIf the downstream service creates independent spans despite receiving traceparent:
OpenTelemetry.Instrumentation.AspNet + AddAspNetInstrumentation() on the server-side TracerProvider to read incoming traceparent headers (AddHttpClientInstrumentation instruments outgoing calls, not incoming)opentelemetry-spring-webmvc-instrumentation on the receiverTextMapPropagator to be configured explicitly to read the header| Mistake | Symptom | Fix |
|---|---|---|
Using --require in an ESM app | Auto-instrumentation silently does nothing | Use --import + --experimental-loader=@opentelemetry/instrumentation/hook.mjs for ESM |
| Setting env vars inside the app | Auto-instrumentation ignores them | Set env vars before process start |
| Bundled auto-instr + expects Transactions | Transactions view empty in Coralogix | Switch to individual method with CoralogixTransactionSampler |
HTTP exporter URL missing /v1/traces path | 404 from Coralogix | Append /v1/traces to the HTTP/proto endpoint URL |
gRPC exporter URL includes /v1/traces path | Connection or export failure | gRPC endpoints have no signal path. Prefer ingress.<region>.coralogix.com:443; https://host:port is also accepted. HTTP/proto uses https://...:443/v1/<signal> |
OTEL_NODE_RESOURCE_DETECTORS=all on local machine | Resource detector errors | Use env,host,os,process locally to suppress errors |
Missing cx.application.name / cx.subsystem.name | APM features degraded | Set as resource attributes in SDK or as OTLP headers |
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10
scenario-11
scenario-12
scenario-13
scenario-14
scenario-15
scenario-16
scenario-17
scenario-18
scenario-19
scenario-20
scenario-21
scenario-22
scenario-23
scenario-24
scenario-25
scenario-26
scenario-27
scenario-28
scenario-29
scenario-30
scenario-31
scenario-32
scenario-33
scenario-34
scenario-35
scenario-36
scenario-37
scenario-38
scenario-39
scenario-40
scenario-41
scenario-42
scenario-43
scenario-44
scenario-45
scenario-46
scenario-47
scenario-48
scenario-49
scenario-50
scenario-51
scenario-52
scenario-53
scenario-54
scenario-55
scenario-56
scenario-57
scenario-58
scenario-59
scenario-60
scenario-61
scenario-62
scenario-63
scenario-64
scenario-65
scenario-66
scenario-67
scenario-68
scenario-69
scenario-70
scenario-71
scenario-72
scenario-73
scenario-74
scenario-75
scenario-76
scenario-77
scenario-78
scenario-79
scenario-80
scenario-81
skills
opentelemetry
opentelemetry-collector
references
opentelemetry-instrumentation
opentelemetry-ottl