UNPKG

n8n

Version:

n8n Workflow Automation Tool

67 lines 2.96 kB
"use strict"; var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; return c > 3 && r && Object.defineProperty(target, key, r), r; }; var __metadata = (this && this.__metadata) || function (k, v) { if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); }; Object.defineProperty(exports, "__esModule", { value: true }); exports.OtelConfig = void 0; const config_1 = require("@n8n/config"); let OtelConfig = class OtelConfig { constructor() { this.enabled = false; this.exporterEndpoint = 'http://localhost:4318'; this.exporterTracingPath = '/v1/traces'; this.exporterHeaders = ''; this.exporterServiceName = 'n8n'; this.tracesSampleRate = 1.0; this.startupConnectivityTimeoutMs = 2_000; this.includeNodeSpans = true; this.injectOutbound = true; } }; exports.OtelConfig = OtelConfig; __decorate([ (0, config_1.Env)('N8N_OTEL_ENABLED'), __metadata("design:type", Boolean) ], OtelConfig.prototype, "enabled", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_EXPORTER_OTLP_ENDPOINT'), __metadata("design:type", String) ], OtelConfig.prototype, "exporterEndpoint", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_EXPORTER_OTLP_TRACING_PATH'), __metadata("design:type", String) ], OtelConfig.prototype, "exporterTracingPath", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_EXPORTER_OTLP_HEADERS'), __metadata("design:type", String) ], OtelConfig.prototype, "exporterHeaders", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_EXPORTER_SERVICE_NAME'), __metadata("design:type", String) ], OtelConfig.prototype, "exporterServiceName", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_TRACES_SAMPLE_RATE'), __metadata("design:type", Number) ], OtelConfig.prototype, "tracesSampleRate", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_STARTUP_CONNECTIVITY_TIMEOUT_MS'), __metadata("design:type", Number) ], OtelConfig.prototype, "startupConnectivityTimeoutMs", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_TRACES_INCLUDE_NODE_SPANS'), __metadata("design:type", Boolean) ], OtelConfig.prototype, "includeNodeSpans", void 0); __decorate([ (0, config_1.Env)('N8N_OTEL_TRACES_INJECT_OUTBOUND'), __metadata("design:type", Boolean) ], OtelConfig.prototype, "injectOutbound", void 0); exports.OtelConfig = OtelConfig = __decorate([ config_1.Config ], OtelConfig); //# sourceMappingURL=otel.config.js.map