UNPKG

n8n

Version:

n8n Workflow Automation Tool

73 lines 3.39 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"); const otel_constants_1 = require("./otel.constants"); 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; this.productionExecutionsOnly = true; } }; exports.OtelConfig = OtelConfig; __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.enabled), __metadata("design:type", Boolean) ], OtelConfig.prototype, "enabled", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.exporterEndpoint), __metadata("design:type", String) ], OtelConfig.prototype, "exporterEndpoint", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.exporterTracingPath), __metadata("design:type", String) ], OtelConfig.prototype, "exporterTracingPath", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.exporterHeaders), __metadata("design:type", String) ], OtelConfig.prototype, "exporterHeaders", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.exporterServiceName), __metadata("design:type", String) ], OtelConfig.prototype, "exporterServiceName", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.tracesSampleRate), __metadata("design:type", Number) ], OtelConfig.prototype, "tracesSampleRate", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.startupConnectivityTimeoutMs), __metadata("design:type", Number) ], OtelConfig.prototype, "startupConnectivityTimeoutMs", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.includeNodeSpans), __metadata("design:type", Boolean) ], OtelConfig.prototype, "includeNodeSpans", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.injectOutbound), __metadata("design:type", Boolean) ], OtelConfig.prototype, "injectOutbound", void 0); __decorate([ (0, config_1.Env)(otel_constants_1.OTEL_ENV_VARS.productionExecutionsOnly), __metadata("design:type", Boolean) ], OtelConfig.prototype, "productionExecutionsOnly", void 0); exports.OtelConfig = OtelConfig = __decorate([ config_1.Config ], OtelConfig); //# sourceMappingURL=otel.config.js.map