@dbos-inc/dbos-sdk 0.7.25-preview → 0.8.12-preview

Sign up to get free protection for your applications and to get access to all the features.
Files changed (125) hide show
  1. package/dist/src/cloud-cli/applications/configure.d.ts.map +1 -1
  2. package/dist/src/cloud-cli/applications/configure.js +12 -2
  3. package/dist/src/cloud-cli/applications/configure.js.map +1 -1
  4. package/dist/src/cloud-cli/applications/delete-app.js +1 -1
  5. package/dist/src/cloud-cli/applications/delete-app.js.map +1 -1
  6. package/dist/src/cloud-cli/applications/deploy-app-code.d.ts.map +1 -1
  7. package/dist/src/cloud-cli/applications/deploy-app-code.js +10 -2
  8. package/dist/src/cloud-cli/applications/deploy-app-code.js.map +1 -1
  9. package/dist/src/cloud-cli/applications/get-app-logs.js +1 -1
  10. package/dist/src/cloud-cli/applications/get-app-logs.js.map +1 -1
  11. package/dist/src/cloud-cli/applications/list-apps.js +1 -1
  12. package/dist/src/cloud-cli/applications/list-apps.js.map +1 -1
  13. package/dist/src/cloud-cli/applications/register-app.js +1 -1
  14. package/dist/src/cloud-cli/applications/register-app.js.map +1 -1
  15. package/dist/src/cloud-cli/applications/update-app.d.ts.map +1 -1
  16. package/dist/src/cloud-cli/applications/update-app.js +3 -2
  17. package/dist/src/cloud-cli/applications/update-app.js.map +1 -1
  18. package/dist/src/cloud-cli/cli.js +19 -7
  19. package/dist/src/cloud-cli/cli.js.map +1 -1
  20. package/dist/src/cloud-cli/login.d.ts.map +1 -1
  21. package/dist/src/cloud-cli/login.js +3 -2
  22. package/dist/src/cloud-cli/login.js.map +1 -1
  23. package/dist/src/cloud-cli/register.js +1 -1
  24. package/dist/src/cloud-cli/register.js.map +1 -1
  25. package/dist/src/cloud-cli/userdb.d.ts +2 -0
  26. package/dist/src/cloud-cli/userdb.d.ts.map +1 -1
  27. package/dist/src/cloud-cli/userdb.js +102 -8
  28. package/dist/src/cloud-cli/userdb.js.map +1 -1
  29. package/dist/src/communicator.d.ts +3 -2
  30. package/dist/src/communicator.d.ts.map +1 -1
  31. package/dist/src/communicator.js.map +1 -1
  32. package/dist/src/context.d.ts +3 -3
  33. package/dist/src/context.d.ts.map +1 -1
  34. package/dist/src/context.js +8 -8
  35. package/dist/src/context.js.map +1 -1
  36. package/dist/src/dbos-executor.d.ts +19 -7
  37. package/dist/src/dbos-executor.d.ts.map +1 -1
  38. package/dist/src/dbos-executor.js +186 -67
  39. package/dist/src/dbos-executor.js.map +1 -1
  40. package/dist/src/dbos-runtime/cli.d.ts +0 -1
  41. package/dist/src/dbos-runtime/cli.d.ts.map +1 -1
  42. package/dist/src/dbos-runtime/cli.js +14 -2
  43. package/dist/src/dbos-runtime/cli.js.map +1 -1
  44. package/dist/src/dbos-runtime/config.d.ts +3 -0
  45. package/dist/src/dbos-runtime/config.d.ts.map +1 -1
  46. package/dist/src/dbos-runtime/config.js +0 -1
  47. package/dist/src/dbos-runtime/config.js.map +1 -1
  48. package/dist/src/dbos-runtime/debug.d.ts +4 -0
  49. package/dist/src/dbos-runtime/debug.d.ts.map +1 -0
  50. package/dist/src/dbos-runtime/debug.js +23 -0
  51. package/dist/src/dbos-runtime/debug.js.map +1 -0
  52. package/dist/src/dbos-runtime/runtime.d.ts +2 -2
  53. package/dist/src/dbos-runtime/runtime.d.ts.map +1 -1
  54. package/dist/src/dbos-runtime/runtime.js +20 -21
  55. package/dist/src/dbos-runtime/runtime.js.map +1 -1
  56. package/dist/src/debugger/debug_workflow.d.ts +8 -8
  57. package/dist/src/debugger/debug_workflow.d.ts.map +1 -1
  58. package/dist/src/debugger/debug_workflow.js +107 -36
  59. package/dist/src/debugger/debug_workflow.js.map +1 -1
  60. package/dist/src/httpServer/handler.d.ts +1 -1
  61. package/dist/src/httpServer/handler.d.ts.map +1 -1
  62. package/dist/src/httpServer/handler.js +14 -14
  63. package/dist/src/httpServer/handler.js.map +1 -1
  64. package/dist/src/httpServer/server.d.ts +4 -4
  65. package/dist/src/httpServer/server.d.ts.map +1 -1
  66. package/dist/src/httpServer/server.js +17 -17
  67. package/dist/src/httpServer/server.js.map +1 -1
  68. package/dist/src/{dbos-runtime → staticAnalysis}/TypeParser.d.ts +4 -0
  69. package/dist/src/staticAnalysis/TypeParser.d.ts.map +1 -0
  70. package/dist/src/{dbos-runtime → staticAnalysis}/TypeParser.js +34 -1
  71. package/dist/src/staticAnalysis/TypeParser.js.map +1 -0
  72. package/dist/src/{dbos-runtime → staticAnalysis}/openApi.d.ts.map +1 -1
  73. package/dist/src/{dbos-runtime → staticAnalysis}/openApi.js +1 -31
  74. package/dist/src/staticAnalysis/openApi.js.map +1 -0
  75. package/dist/src/staticAnalysis/tsDiagUtil.d.ts.map +1 -0
  76. package/dist/src/staticAnalysis/tsDiagUtil.js.map +1 -0
  77. package/dist/src/system_database.d.ts +22 -9
  78. package/dist/src/system_database.d.ts.map +1 -1
  79. package/dist/src/system_database.js +44 -42
  80. package/dist/src/system_database.js.map +1 -1
  81. package/dist/src/telemetry/collector.d.ts +5 -5
  82. package/dist/src/telemetry/collector.d.ts.map +1 -1
  83. package/dist/src/telemetry/collector.js +5 -17
  84. package/dist/src/telemetry/collector.js.map +1 -1
  85. package/dist/src/telemetry/exporters.d.ts +11 -24
  86. package/dist/src/telemetry/exporters.d.ts.map +1 -1
  87. package/dist/src/telemetry/exporters.js +42 -129
  88. package/dist/src/telemetry/exporters.js.map +1 -1
  89. package/dist/src/telemetry/index.d.ts +6 -2
  90. package/dist/src/telemetry/index.d.ts.map +1 -1
  91. package/dist/src/telemetry/index.js +16 -0
  92. package/dist/src/telemetry/index.js.map +1 -1
  93. package/dist/src/telemetry/logs.d.ts +35 -11
  94. package/dist/src/telemetry/logs.d.ts.map +1 -1
  95. package/dist/src/telemetry/logs.js +158 -53
  96. package/dist/src/telemetry/logs.js.map +1 -1
  97. package/dist/src/telemetry/traces.d.ts +1 -6
  98. package/dist/src/telemetry/traces.d.ts.map +1 -1
  99. package/dist/src/telemetry/traces.js +2 -34
  100. package/dist/src/telemetry/traces.js.map +1 -1
  101. package/dist/src/testing/testing_runtime.d.ts +1 -1
  102. package/dist/src/testing/testing_runtime.d.ts.map +1 -1
  103. package/dist/src/testing/testing_runtime.js +8 -2
  104. package/dist/src/testing/testing_runtime.js.map +1 -1
  105. package/dist/src/transaction.d.ts +1 -1
  106. package/dist/src/transaction.d.ts.map +1 -1
  107. package/dist/src/workflow.d.ts +16 -1
  108. package/dist/src/workflow.d.ts.map +1 -1
  109. package/dist/src/workflow.js +103 -61
  110. package/dist/src/workflow.js.map +1 -1
  111. package/examples/hello/README.md +1 -1
  112. package/examples/hello/dbos-config.yaml +3 -0
  113. package/package.json +3 -2
  114. package/dist/src/dbos-runtime/TypeParser.d.ts.map +0 -1
  115. package/dist/src/dbos-runtime/TypeParser.js.map +0 -1
  116. package/dist/src/dbos-runtime/openApi.js.map +0 -1
  117. package/dist/src/dbos-runtime/tsDiagUtil.d.ts.map +0 -1
  118. package/dist/src/dbos-runtime/tsDiagUtil.js.map +0 -1
  119. package/dist/src/telemetry/signals.d.ts +0 -20
  120. package/dist/src/telemetry/signals.d.ts.map +0 -1
  121. package/dist/src/telemetry/signals.js +0 -11
  122. package/dist/src/telemetry/signals.js.map +0 -1
  123. /package/dist/src/{dbos-runtime → staticAnalysis}/openApi.d.ts +0 -0
  124. /package/dist/src/{dbos-runtime → staticAnalysis}/tsDiagUtil.d.ts +0 -0
  125. /package/dist/src/{dbos-runtime → staticAnalysis}/tsDiagUtil.js +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"system_database.js","sourceRoot":"","sources":["../../src/system_database.ts"],"names":[],"mappings":";AAAA,uDAAuD;;;AAEvD,qDAAmE;AACnE,mDAAmE;AACnE,2BAAuF;AACvF,mCAAqF;AACrF,yCAA0D;AAC1D,kEAAkJ;AAClJ,mCAAgC;AAInB,QAAA,oBAAoB,GAAG,kBAAkB,CAAC;AA6BvD,MAAa,sBAAsB;IASZ;IAAmC;IAAqC;IARpF,IAAI,CAAO;IAEpB,mBAAmB,GAAsB,IAAI,CAAC;IACrC,gBAAgB,GAA+B,EAAE,CAAC;IACl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I,GAAG,CAAC,OAAO,IAAI,GAAG,CAAC,OAAO,IAAI,IAAI,CAAC,gBAAgB,EAAE;oBACvD,IAAI,CAAC,gBAAgB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC;iBACtC;aACF;iBAAM;gBACL,IAAI,GAAG,CAAC,OAAO,IAAI,GAAG,CAAC,OAAO,IAAI,IAAI,CAAC,iBAAiB,EAAE;oBACxD,IAAI,CAAC,iBAAiB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC;iBACvC;aACF;QACH,CAAC,CAAC;QACF,IAAI,CAAC,mBAAmB,CAAC,EAAE,CAAC,cAAc,EAAE,OAAO,CAAC,CAAC;IACvD,CAAC;CACF;AAlaD,wDAkaC"}
@@ -1,14 +1,14 @@
1
- import { MethodRegistrationBase } from "../decorators";
2
1
  import { ITelemetryExporter } from "./exporters";
3
- import { TelemetrySignal } from "./signals";
2
+ import { Span } from "@opentelemetry/sdk-trace-base";
3
+ import { LogRecord } from "@opentelemetry/api-logs";
4
+ export type TelemetrySignal = LogRecord | Span;
4
5
  export declare class TelemetryCollector {
5
- readonly exporters: ITelemetryExporter<any, any>[];
6
+ readonly exporter?: ITelemetryExporter | undefined;
6
7
  private readonly signals;
7
8
  private readonly signalBufferID;
8
9
  private readonly processAndExportSignalsIntervalMs;
9
10
  private readonly processAndExportSignalsMaxBatchSize;
10
- constructor(exporters: ITelemetryExporter<any, any>[]);
11
- init(registeredOperations?: Array<MethodRegistrationBase>): Promise<void>;
11
+ constructor(exporter?: ITelemetryExporter | undefined);
12
12
  destroy(): Promise<void>;
13
13
  push(signal: TelemetrySignal): void;
14
14
  private pop;
@@ -1 +1 @@
1
- {"version":3,"file":"collector.d.ts","sourceRoot":"","sources":["../../../src/telemetry/collector.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,eAAe,CAAC;AACvD,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,e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C,IAAI,CAAC;CAqB/C"}
@@ -15,34 +15,22 @@ class SignalsQueue {
15
15
  }
16
16
  // TODO: Handle temporary workflows properly.
17
17
  class TelemetryCollector {
18
- exporters;
18
+ exporter;
19
19
  // Signals buffer management
20
20
  signals = new SignalsQueue();
21
21
  signalBufferID;
22
22
  processAndExportSignalsIntervalMs = 1000;
23
23
  processAndExportSignalsMaxBatchSize = 10;
24
24
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
25
- constructor(exporters) {
26
- this.exporters = exporters;
25
+ constructor(exporter) {
26
+ this.exporter = exporter;
27
27
  this.signalBufferID = setInterval(() => {
28
28
  void this.processAndExportSignals();
29
29
  }, this.processAndExportSignalsIntervalMs);
30
30
  }
31
- async init(registeredOperations = []) {
32
- for (const exporter of this.exporters) {
33
- if (exporter.init) {
34
- await exporter.init(registeredOperations);
35
- }
36
- }
37
- }
38
31
  async destroy() {
39
32
  clearInterval(this.signalBufferID);
40
33
  await this.processAndExportSignals();
41
- for (const exporter of this.exporters) {
42
- if (exporter.destroy) {
43
- await exporter.destroy();
44
- }
45
- }
46
34
  }
47
35
  push(signal) {
48
36
  this.signals.push(signal);
@@ -61,8 +49,8 @@ class TelemetryCollector {
61
49
  }
62
50
  if (batch.length > 0) {
63
51
  const exports = [];
64
- for (const exporter of this.exporters) {
65
- exports.push(exporter.export(batch));
52
+ if (this.exporter) {
53
+ exports.push(this.exporter.export(batch));
66
54
  }
67
55
  try {
68
56
  await Promise.all(exports);
@@ -1 +1 @@
1
- {"version":3,"file":"collector.js","sourceRoot":"","sources":["../../../src/telemetry/collector.ts"],"names":[],"mappings":";;;AAIA,MAAM,YAAY;IAChB,IAAI,GAAsB,EAAE,CAAC;IAE7B,IAAI,CAAC,MAAuB;QAC1B,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;IACzB,CAAC;IAED,GAAG;QACD,OAAO,IAAI,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC;IAC3B,CAAC;IAED,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CAAE,CAAW,CAAC,OAAO,CAAC,CAAC;aACrC;SACF;IACH,CAAC;CACF;AAhDD,gDAgDC"}
@@ -1,28 +1,15 @@
1
- import { Client, QueryConfig, QueryArrayResult, PoolConfig } from "pg";
2
- import { DBOSDataType, MethodRegistrationBase } from "./../decorators";
3
- import { TelemetrySignal } from "./signals";
4
- export interface ITelemetryExporter<T, U> {
5
- export(signal: TelemetrySignal[]): Promise<T>;
6
- process?(signal: TelemetrySignal[]): U;
7
- init?(registeredOperations?: ReadonlyArray<MethodRegistrationBase>): Promise<void>;
8
- destroy?(): Promise<void>;
1
+ import { TelemetrySignal } from "./collector";
2
+ export interface OTLPExporterConfig {
3
+ logsEndpoint?: string;
4
+ tracesEndpoint?: string;
9
5
  }
10
- export declare const JAEGER_EXPORTER = "JaegerExporter";
11
- export declare class JaegerExporter implements ITelemetryExporter<void, undefined> {
12
- private readonly exporter;
13
- constructor(endpoint?: string);
14
- export(signals: TelemetrySignal[]): Promise<void>;
6
+ export interface ITelemetryExporter {
7
+ export(signal: TelemetrySignal[]): Promise<void>;
15
8
  }
16
- export declare const POSTGRES_EXPORTER = "PostgresExporter";
17
- export declare class PostgresExporter implements ITelemetryExporter<QueryArrayResult[], QueryConfig[]> {
18
- private readonly poolConfig;
19
- readonly observabilityDBName: string;
20
- readonly pgClient: Client;
21
- constructor(poolConfig: PoolConfig, observabilityDBName?: string);
22
- static getPGDataType(t: DBOSDataType): string;
23
- init(registeredOperations?: ReadonlyArray<MethodRegistrationBase>): Promise<void>;
24
- destroy(): Promise<void>;
25
- process(signals: TelemetrySignal[]): QueryConfig[];
26
- export(telemetrySignals: TelemetrySignal[]): Promise<QueryArrayResult[]>;
9
+ export declare class TelemetryExporter implements ITelemetryExporter {
10
+ private readonly tracesExporter?;
11
+ private readonly logsExporter?;
12
+ constructor(config: OTLPExporterConfig);
13
+ export(signals: TelemetrySignal[]): Promise<void>;
27
14
  }
28
15
  //# sourceMappingURL=exporters.d.ts.map
@@ -1 +1 @@
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AC,EAAE,YAAY,GAAG,MAAM;IAOvC,IAAI,CAAC,oBAAoB,GAAE,aAAa,CAAC,sBAAsB,CAAM;IA2CrE,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;IAI9B,OAAO,CAAC,OAAO,EAAE,eAAe,EAAE,GAAG,WAAW,EAAE;IAkC5C,MAAM,CAAC,gBAAgB,EAAE,eAAe,EAAE,GAAG,OAAO,CAAC,gBAAgB,EAAE,CAAC;CAiB/E"}
1
+ {"version":3,"file":"exporters.d.ts","sourceRoot":"","sources":["../../../src/telemetry/exporters.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AAQ9C,MAAM,WAAW,kBAAkB;IACjC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,MAAM,EAAE,eAAe,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAClD;AAED,qBAAa,iBAAkB,YAAW,kBAAkB;IAC1D,OAAO,CAAC,QAAQ,CAAC,cAAc,CAAC,CAAoB;IACpD,OAAO,CAAC,QAAQ,CAAC,YAAY,CAAC,CAAkB;gBACpC,MAAM,EAAE,kBAAkB;IAehC,MAAM,CAAC,OAAO,EAAE,eAAe,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;CAmCxD"}
@@ -1,146 +1,59 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PostgresExporter = exports.POSTGRES_EXPORTER = exports.JaegerExporter = exports.JAEGER_EXPORTER = void 0;
4
- const pg_1 = require("pg");
5
- const lodash_1 = require("lodash");
6
- const decorators_1 = require("./../decorators");
7
- const error_1 = require("./../error");
3
+ exports.TelemetryExporter = void 0;
4
+ const _1 = require("./");
8
5
  const exporter_trace_otlp_http_1 = require("@opentelemetry/exporter-trace-otlp-http");
6
+ const exporter_logs_otlp_http_1 = require("@opentelemetry/exporter-logs-otlp-http");
9
7
  const core_1 = require("@opentelemetry/core");
10
- const traces_1 = require("./traces");
11
- exports.JAEGER_EXPORTER = "JaegerExporter";
12
- class JaegerExporter {
13
- exporter;
14
- constructor(endpoint = "http://localhost:4318/v1/traces") {
15
- this.exporter = new exporter_trace_otlp_http_1.OTLPTraceExporter({
16
- url: endpoint,
17
- });
8
+ class TelemetryExporter {
9
+ tracesExporter;
10
+ logsExporter;
11
+ constructor(config) {
12
+ if (config.tracesEndpoint) {
13
+ this.tracesExporter = new exporter_trace_otlp_http_1.OTLPTraceExporter({
14
+ url: config.tracesEndpoint,
15
+ });
16
+ console.log(`Traces will be exported to ${config.tracesEndpoint}`);
17
+ }
18
+ if (config.logsEndpoint) {
19
+ this.logsExporter = new exporter_logs_otlp_http_1.OTLPLogExporter({
20
+ url: config.logsEndpoint,
21
+ });
22
+ console.log(`Logs will be exported to ${config.logsEndpoint}`);
23
+ }
18
24
  }
19
25
  async export(signals) {
20
26
  return await new Promise((resolve) => {
27
+ // Sort out traces and logs
21
28
  const exportSpans = [];
29
+ const exportLogs = [];
22
30
  signals.forEach((signal) => {
23
- if (signal.traceSpan) {
24
- exportSpans.push(signal.traceSpan);
31
+ if ((0, _1.isTraceSignal)(signal)) {
32
+ exportSpans.push(signal);
25
33
  }
26
- });
27
- this.exporter.export(exportSpans, (results) => {
28
- if (results.code !== core_1.ExportResultCode.SUCCESS) {
29
- console.warn(`Jaeger export failed`);
34
+ if ((0, _1.isLogSignal)(signal)) {
35
+ exportLogs.push(signal);
30
36
  }
31
37
  });
32
- resolve();
33
- });
34
- }
35
- }
36
- exports.JaegerExporter = JaegerExporter;
37
- exports.POSTGRES_EXPORTER = "PostgresExporter";
38
- class PostgresExporter {
39
- poolConfig;
40
- observabilityDBName;
41
- pgClient;
42
- constructor(poolConfig, observabilityDBName = "dbos_observability") {
43
- this.poolConfig = poolConfig;
44
- this.observabilityDBName = observabilityDBName;
45
- const pgClientConfig = { ...poolConfig };
46
- pgClientConfig.database = this.observabilityDBName;
47
- this.pgClient = new pg_1.Client(pgClientConfig);
48
- }
49
- static getPGDataType(t) {
50
- if (t.dataType === "double") {
51
- return "double precision"; // aka "float8"
52
- }
53
- return t.formatAsString();
54
- }
55
- async init(registeredOperations = []) {
56
- const pgSystemClient = new pg_1.Client(this.poolConfig);
57
- await pgSystemClient.connect();
58
- // First check if the log database exists using pgSystemClient.
59
- const dbExists = await pgSystemClient.query(`SELECT FROM pg_database WHERE datname = '${this.observabilityDBName}'`);
60
- if (dbExists.rows.length === 0) {
61
- // Create the logs backend database
62
- await pgSystemClient.query(`CREATE DATABASE ${this.observabilityDBName}`);
63
- }
64
- await pgSystemClient.end();
65
- // Connect the exporter client
66
- await this.pgClient.connect();
67
- // Configure tables for registered workflows
68
- for (const registeredOperation of registeredOperations) {
69
- const tableName = `signal_${registeredOperation.name}`;
70
- let createSignalTableQuery = `CREATE TABLE IF NOT EXISTS ${tableName} (
71
- workflow_uuid TEXT NOT NULL,
72
- function_name TEXT NOT NULL,
73
- run_as TEXT NOT NULL,
74
- timestamp BIGINT NOT NULL,
75
- transaction_id TEXT DEFAULT NULL,
76
- trace_id TEXT DEFAULT NULL,
77
- trace_span JSONB DEFAULT NULL,\n`;
78
- for (const arg of registeredOperation.args) {
79
- if (arg.logMask === decorators_1.LogMasks.SKIP) {
80
- continue;
81
- }
82
- else if (arg.logMask === decorators_1.LogMasks.HASH) {
83
- const row = `${arg.name} VARCHAR(64) DEFAULT NULL,\n`;
84
- createSignalTableQuery = createSignalTableQuery.concat(row);
85
- }
86
- else {
87
- const row = `${arg.name} ${PostgresExporter.getPGDataType(arg.dataType)} DEFAULT NULL,\n`;
88
- createSignalTableQuery = createSignalTableQuery.concat(row);
89
- }
38
+ if (exportSpans.length > 0 && this.tracesExporter) {
39
+ this.tracesExporter.export(exportSpans, (results) => {
40
+ if (results.code !== core_1.ExportResultCode.SUCCESS) {
41
+ console.warn(`Trace export failed: ${results.code}`);
42
+ console.warn(results);
43
+ }
44
+ });
90
45
  }
91
- // Trim last comma and line feed
92
- createSignalTableQuery = createSignalTableQuery.slice(0, -2).concat("\n);");
93
- await this.pgClient.query(createSignalTableQuery);
94
- }
95
- }
96
- async destroy() {
97
- await this.pgClient.end();
98
- }
99
- process(signals) {
100
- const groupByFunctionName = new Map(Object.entries((0, lodash_1.groupBy)(signals, ({ operationName }) => operationName)));
101
- const queries = [];
102
- for (const [operationName, signals] of groupByFunctionName) {
103
- const tableName = `signal_${operationName}`;
104
- const query = `
105
- INSERT INTO ${tableName}
106
- SELECT * FROM jsonb_to_recordset($1::jsonb) AS tmp (workflow_uuid text, function_name text, run_as text, timestamp bigint, transaction_id text, trace_id text, trace_span json)
107
- `;
108
- const values = JSON.stringify(signals.map((signal) => {
109
- return {
110
- workflow_uuid: signal.workflowUUID,
111
- function_name: signal.operationName,
112
- run_as: signal.runAs,
113
- timestamp: signal.timestamp,
114
- transaction_id: signal.transactionID,
115
- trace_id: signal.traceID,
116
- trace_span: signal.traceSpan ? (0, traces_1.spanToString)(signal.traceSpan) : null,
117
- };
118
- }));
119
- queries.push({
120
- name: `insert-${tableName}`,
121
- text: query,
122
- values: [values],
123
- });
124
- }
125
- return queries;
126
- }
127
- async export(telemetrySignals) {
128
- const results = [];
129
- // Find all telemetry signals and process.
130
- if (telemetrySignals.length > 0) {
131
- const queries = this.process(telemetrySignals);
132
- for (const query of queries) {
133
- results.push(this.pgClient.query(query));
46
+ if (exportLogs.length > 0 && this.logsExporter) {
47
+ this.logsExporter.export(exportLogs, (results) => {
48
+ if (results.code !== core_1.ExportResultCode.SUCCESS) {
49
+ console.warn(`Log export failed: ${results.code}`);
50
+ console.warn(results);
51
+ }
52
+ });
134
53
  }
135
- }
136
- try {
137
- // We do await here so we can catch and format PostgresExporter specific errors
138
- return await Promise.all(results);
139
- }
140
- catch (err) {
141
- throw new error_1.DBOSPostgresExporterError(err);
142
- }
54
+ resolve();
55
+ });
143
56
  }
144
57
  }
145
- exports.PostgresExporter = PostgresExporter;
58
+ exports.TelemetryExporter = TelemetryExporter;
146
59
  //# sourceMappingURL=exporters.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"exporters.js","sourceRoot":"","sources":["../../../src/telemetry/exporters.ts"],"names":[],"mappings":";;;AAAA,2BAAuE;AACvE,mCAAiC;AACjC,gDAAiF;AACjF,sCAAuD;AAEvD,sFAA4E;AAE5E,8CAAqE;AACrE,qCAAwC;AAS3B,QAAA,eAAe,GAAG,gBAAgB,CAAC;AAChD,MAAa,cAAc;IACR,QAAQ,CAAoB;IAC7C,YAAY,WAAmB,iCAAiC;QAC9D,IAAI,CAAC,QAAQ,GAAG,IAAI,4CAAiB,CAAC;YACpC,GAAG,EAAE,QAAQ;SACd,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,OAA0B;QACrC,OAAO,MAAM,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,EAAE;YACzC,MAAM,WAAW,GAAmB,EAAE,CAAC;YACvC,OAAO,CAAC,OAAO,CAAC,CAAC,MAAM,EAAE,EAAE;gBACzB,IAAI,MAAM,CAAC,SAAS,EAAE;oBACpB,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC;iBACpC;YACH,CAAC,CAAC,CAAC;YACH,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,WAAW,EAAE,CAAC,OAAqB,EAAE,EAAE;gBAC1D,IAAI,OAAO,CAAC,IAAI,KAAK,uBAAgB,CAAC,OAAO,EAAE;oBAC7C,OAAO,CAAC,IAAI,CAAC,sBAAsB,CAAC,CAAC;iBACtC;YACH,CAAC,CAAC,CAAC;YACH,OAAO,EAAE,CAAC;QACZ,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AAxBD,wCAwBC;AAEY,QAAA,iBAAiB,GAAG,kBAAkB,CAAC;AACpD,MAAa,gBAAgB;IAGE;IAAiC;IAFrD,QAAQ,CAAS;IAE1B,YAA6B,UAAsB,EAAW,sBAA8B,o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AAc,EAAE;gBACjD,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,WAAW,EAAE,CAAC,OAAqB,EAAE,EAAE;oBAChE,IAAI,OAAO,CAAC,IAAI,KAAK,uBAAgB,CAAC,OAAO,EAAE;wBAC7C,OAAO,CAAC,IAAI,CAAC,wBAAwB,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;wBACrD,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;qBACvB;gBACH,CAAC,CAAC,CAAC;aACJ;YAED,IAAI,UAAU,CAAC,MAAM,GAAG,CAAC,IAAI,IAAI,CAAC,YAAY,EAAE;gBAC9C,IAAI,CAAC,YAAY,CAAC,MAAM,CAAC,UAAU,EAAE,CAAC,OAAqB,EAAE,EAAE;oBAC7D,IAAI,OAAO,CAAC,IAAI,KAAK,uBAAgB,CAAC,OAAO,EAAE;wBAC7C,OAAO,CAAC,IAAI,CAAC,sBAAsB,OAAO,CAAC,IAAI,EAAE,CAAC,CAAC;wBACnD,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;qBACvB;gBACH,CAAC,CAAC,CAAC;aACJ;YAED,OAAO,EAAE,CAAC;QACZ,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AArDD,8CAqDC"}
@@ -1,7 +1,11 @@
1
1
  import { LoggerConfig } from "./logs";
2
- import { TracerConfig } from "./traces";
2
+ import { OTLPExporterConfig } from "./exporters";
3
+ import { Span } from "@opentelemetry/sdk-trace-base";
4
+ import { LogRecord } from "@opentelemetry/api-logs";
5
+ export declare function isTraceSignal(signal: any): signal is Span;
6
+ export declare function isLogSignal(signal: any): signal is LogRecord;
3
7
  export interface TelemetryConfig {
4
8
  logs?: LoggerConfig;
5
- traces?: TracerConfig;
9
+ OTLPExporter?: OTLPExporterConfig;
6
10
  }
7
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/telemetry/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAExC,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,MAAM,CAAC,EAAE,YAAY,CAAC;CACvB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/telemetry/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,QAAQ,CAAC;AACtC,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AACjD,OAAO,EAAE,IAAI,EAAE,MAAM,+BAA+B,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAIpD,wBAAgB,aAAa,CAAC,MAAM,EAAE,GAAG,GAAG,MAAM,IAAI,IAAI,CAIzD;AAGD,wBAAgB,WAAW,CAAC,MAAM,EAAE,GAAG,GAAG,MAAM,IAAI,SAAS,CAI5D;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,YAAY,CAAC;IACpB,YAAY,CAAC,EAAE,kBAAkB,CAAC;CACnC"}
@@ -1,3 +1,19 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isLogSignal = exports.isTraceSignal = void 0;
4
+ // We could implement our own types and avoid having `any`, but this has likely little value
5
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
6
+ function isTraceSignal(signal) {
7
+ // Span is an interface that has a property 'kind'
8
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-return
9
+ return signal && 'kind' in signal;
10
+ }
11
+ exports.isTraceSignal = isTraceSignal;
12
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
13
+ function isLogSignal(signal) {
14
+ // LogRecord is an interface that has a property 'severityText' and 'severityNumber'
15
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-return
16
+ return signal && 'severityText' in signal && 'severityNumber' in signal;
17
+ }
18
+ exports.isLogSignal = isLogSignal;
3
19
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/telemetry/index.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/telemetry/index.ts"],"names":[],"mappings":";;;AAKA,4FAA4F;AAC5F,8DAA8D;AAC9D,SAAgB,aAAa,CAAC,MAAW;IACvC,kDAAkD;IAClD,+DAA+D;IAC/D,OAAO,MAAM,IAAI,MAAM,IAAI,MAAM,CAAC;AACpC,CAAC;AAJD,sCAIC;AAED,8DAA8D;AAC9D,SAAgB,WAAW,CAAC,MAAW;IACrC,oFAAoF;IACpF,+DAA+D;IAC/D,OAAO,MAAM,IAAI,cAAc,IAAI,MAAM,IAAI,gBAAgB,IAAI,MAAM,CAAC;AAC1E,CAAC;AAJD,kCAIC"}
@@ -1,25 +1,49 @@
1
1
  import { Logger as IWinstonLogger } from "winston";
2
2
  import { DBOSContext } from "../context";
3
+ import { TelemetryCollector } from "./collector";
4
+ /*****************/
5
+ /*****************/
3
6
  export interface LoggerConfig {
4
7
  logLevel?: string;
5
8
  silent?: boolean;
6
9
  addContextMetadata?: boolean;
7
10
  }
8
- export interface WinstonLogger extends IWinstonLogger {
9
- addContextMetadata: boolean;
11
+ type ContextualMetadata = {
12
+ includeContextMetadata?: boolean;
13
+ workflowUUID: string;
14
+ authenticatedUser: string;
15
+ traceId: string;
16
+ spanId: string;
17
+ };
18
+ interface StackTrace {
19
+ stack?: string;
10
20
  }
21
+ export interface IGlobalLogger extends IWinstonLogger {
22
+ readonly addContextMetadata: boolean;
23
+ readonly logger: IWinstonLogger;
24
+ readonly telemetryCollector: TelemetryCollector;
25
+ }
26
+ export declare class GlobalLogger {
27
+ private readonly telemetryCollector?;
28
+ private readonly logger;
29
+ readonly addContextMetadata: boolean;
30
+ constructor(telemetryCollector?: TelemetryCollector | undefined, config?: LoggerConfig);
31
+ info(logEntry: any, metadata?: ContextualMetadata): void;
32
+ debug(logEntry: any, metadata?: ContextualMetadata): void;
33
+ warn(logEntry: any, metadata?: ContextualMetadata): void;
34
+ error(inputError: any, metadata?: ContextualMetadata & StackTrace): void;
35
+ }
36
+ /******************/
37
+ /******************/
11
38
  export declare class Logger {
12
39
  private readonly globalLogger;
13
40
  private readonly ctx;
14
- readonly metadata: object;
15
- constructor(globalLogger: WinstonLogger, ctx: DBOSContext);
16
- info(message: string): void;
17
- debug(message: string): void;
18
- warn(message: string): void;
19
- emerg(message: string): void;
20
- alert(message: string): void;
21
- crit(message: string): void;
41
+ readonly metadata: ContextualMetadata;
42
+ constructor(globalLogger: GlobalLogger, ctx: DBOSContext);
43
+ info(logEntry: any): void;
44
+ debug(logEntry: any): void;
45
+ warn(logEntry: any): void;
22
46
  error(inputError: any): void;
23
47
  }
24
- export declare function createGlobalLogger(config?: LoggerConfig): WinstonLogger;
48
+ export {};
25
49
  //# sourceMappingURL=logs.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"logs.d.ts","sourceRoot":"","sources":["../../../src/telemetry/logs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoC,MAAM,IAAI,cAAc,EAAE,MAAM,SAAS,CAAC;AAErF,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAEzC,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B;AAGD,MAAM,WAAW,aAAc,SAAQ,cAAc;IACnD,kBAAkB,EAAE,OAAO,CAAC;CAC7B;AAKD,qBAAa,MAAM;IAGL,OAAO,CAAC,QAAQ,CAAC,YAAY;IAAiB,OAAO,CAAC,QAAQ,CAAC,GAAG;IAD9E,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAM;gBACF,YAAY,EAAE,aAAa,EAAmB,GAAG,EAAE,WAAW;IAW3F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