@dbos-inc/dbos-sdk 0.7.35 → 0.8.14-preview
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/src/cloud-cli/applications/configure.d.ts +1 -1
- package/dist/src/cloud-cli/applications/configure.d.ts.map +1 -1
- package/dist/src/cloud-cli/applications/configure.js +35 -28
- package/dist/src/cloud-cli/applications/configure.js.map +1 -1
- package/dist/src/cloud-cli/applications/delete-app.js +1 -1
- package/dist/src/cloud-cli/applications/delete-app.js.map +1 -1
- package/dist/src/cloud-cli/applications/deploy-app-code.d.ts.map +1 -1
- package/dist/src/cloud-cli/applications/deploy-app-code.js +10 -2
- package/dist/src/cloud-cli/applications/deploy-app-code.js.map +1 -1
- package/dist/src/cloud-cli/applications/get-app-logs.js +1 -1
- package/dist/src/cloud-cli/applications/get-app-logs.js.map +1 -1
- package/dist/src/cloud-cli/applications/list-apps.js +1 -1
- package/dist/src/cloud-cli/applications/list-apps.js.map +1 -1
- package/dist/src/cloud-cli/applications/register-app.js +1 -1
- package/dist/src/cloud-cli/applications/register-app.js.map +1 -1
- package/dist/src/cloud-cli/applications/update-app.d.ts.map +1 -1
- package/dist/src/cloud-cli/applications/update-app.js +3 -2
- package/dist/src/cloud-cli/applications/update-app.js.map +1 -1
- package/dist/src/cloud-cli/cli.js +6 -6
- package/dist/src/cloud-cli/cli.js.map +1 -1
- package/dist/src/cloud-cli/login.d.ts.map +1 -1
- package/dist/src/cloud-cli/login.js +3 -2
- package/dist/src/cloud-cli/login.js.map +1 -1
- package/dist/src/cloud-cli/register.js +1 -1
- package/dist/src/cloud-cli/register.js.map +1 -1
- package/dist/src/cloud-cli/userdb.d.ts +10 -2
- package/dist/src/cloud-cli/userdb.d.ts.map +1 -1
- package/dist/src/cloud-cli/userdb.js +63 -100
- package/dist/src/cloud-cli/userdb.js.map +1 -1
- package/dist/src/communicator.d.ts +1 -1
- package/dist/src/communicator.d.ts.map +1 -1
- package/dist/src/context.d.ts +1 -1
- package/dist/src/context.d.ts.map +1 -1
- package/dist/src/context.js +1 -1
- package/dist/src/context.js.map +1 -1
- package/dist/src/dbos-executor.d.ts +18 -7
- package/dist/src/dbos-executor.d.ts.map +1 -1
- package/dist/src/dbos-executor.js +155 -52
- package/dist/src/dbos-executor.js.map +1 -1
- package/dist/src/dbos-runtime/cli.d.ts +0 -1
- package/dist/src/dbos-runtime/cli.d.ts.map +1 -1
- package/dist/src/dbos-runtime/cli.js +14 -2
- package/dist/src/dbos-runtime/cli.js.map +1 -1
- package/dist/src/dbos-runtime/config.d.ts +0 -1
- package/dist/src/dbos-runtime/config.d.ts.map +1 -1
- package/dist/src/dbos-runtime/config.js +0 -1
- package/dist/src/dbos-runtime/config.js.map +1 -1
- package/dist/src/dbos-runtime/debug.d.ts +4 -0
- package/dist/src/dbos-runtime/debug.d.ts.map +1 -0
- package/dist/src/dbos-runtime/debug.js +23 -0
- package/dist/src/dbos-runtime/debug.js.map +1 -0
- package/dist/src/dbos-runtime/runtime.d.ts +1 -1
- package/dist/src/dbos-runtime/runtime.d.ts.map +1 -1
- package/dist/src/dbos-runtime/runtime.js +13 -14
- package/dist/src/dbos-runtime/runtime.js.map +1 -1
- package/dist/src/debugger/debug_workflow.js +6 -6
- package/dist/src/debugger/debug_workflow.js.map +1 -1
- package/dist/src/httpServer/server.d.ts +1 -1
- package/dist/src/httpServer/server.d.ts.map +1 -1
- package/dist/src/{dbos-runtime → staticAnalysis}/TypeParser.d.ts +4 -0
- package/dist/src/staticAnalysis/TypeParser.d.ts.map +1 -0
- package/dist/src/{dbos-runtime → staticAnalysis}/TypeParser.js +34 -1
- package/dist/src/staticAnalysis/TypeParser.js.map +1 -0
- package/dist/src/{dbos-runtime → staticAnalysis}/openApi.d.ts.map +1 -1
- package/dist/src/{dbos-runtime → staticAnalysis}/openApi.js +1 -31
- package/dist/src/staticAnalysis/openApi.js.map +1 -0
- package/dist/src/staticAnalysis/tsDiagUtil.d.ts.map +1 -0
- package/dist/src/staticAnalysis/tsDiagUtil.js.map +1 -0
- package/dist/src/system_database.d.ts +20 -9
- package/dist/src/system_database.d.ts.map +1 -1
- package/dist/src/system_database.js +36 -41
- package/dist/src/system_database.js.map +1 -1
- package/dist/src/telemetry/collector.d.ts +5 -5
- package/dist/src/telemetry/collector.d.ts.map +1 -1
- package/dist/src/telemetry/collector.js +5 -17
- package/dist/src/telemetry/collector.js.map +1 -1
- package/dist/src/telemetry/exporters.d.ts +11 -24
- package/dist/src/telemetry/exporters.d.ts.map +1 -1
- package/dist/src/telemetry/exporters.js +42 -129
- package/dist/src/telemetry/exporters.js.map +1 -1
- package/dist/src/telemetry/index.d.ts +6 -2
- package/dist/src/telemetry/index.d.ts.map +1 -1
- package/dist/src/telemetry/index.js +16 -0
- package/dist/src/telemetry/index.js.map +1 -1
- package/dist/src/telemetry/logs.d.ts +35 -11
- package/dist/src/telemetry/logs.d.ts.map +1 -1
- package/dist/src/telemetry/logs.js +158 -53
- package/dist/src/telemetry/logs.js.map +1 -1
- package/dist/src/telemetry/traces.d.ts +1 -6
- package/dist/src/telemetry/traces.d.ts.map +1 -1
- package/dist/src/telemetry/traces.js +2 -34
- package/dist/src/telemetry/traces.js.map +1 -1
- package/dist/src/testing/testing_runtime.d.ts +1 -1
- package/dist/src/testing/testing_runtime.js +1 -1
- package/dist/src/transaction.d.ts +1 -1
- package/dist/src/transaction.d.ts.map +1 -1
- package/dist/src/workflow.d.ts +2 -0
- package/dist/src/workflow.d.ts.map +1 -1
- package/dist/src/workflow.js +18 -13
- package/dist/src/workflow.js.map +1 -1
- package/examples/hello/dbos-config.yaml +0 -1
- package/package.json +3 -2
- package/dist/src/dbos-runtime/TypeParser.d.ts.map +0 -1
- package/dist/src/dbos-runtime/TypeParser.js.map +0 -1
- package/dist/src/dbos-runtime/openApi.js.map +0 -1
- package/dist/src/dbos-runtime/tsDiagUtil.d.ts.map +0 -1
- package/dist/src/dbos-runtime/tsDiagUtil.js.map +0 -1
- package/dist/src/telemetry/signals.d.ts +0 -20
- package/dist/src/telemetry/signals.d.ts.map +0 -1
- package/dist/src/telemetry/signals.js +0 -11
- package/dist/src/telemetry/signals.js.map +0 -1
- /package/dist/src/{dbos-runtime → staticAnalysis}/openApi.d.ts +0 -0
- /package/dist/src/{dbos-runtime → staticAnalysis}/tsDiagUtil.d.ts +0 -0
- /package/dist/src/{dbos-runtime → staticAnalysis}/tsDiagUtil.js +0 -0
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../../src/dbos-runtime/runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAa5D,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,qBAAa,WAAW;IAIc,OAAO,CAAC,QAAQ,CAAC,aAAa;IAHlE,OAAO,CAAC,QAAQ,CAAe;IAC/B,OAAO,CAAC,MAAM,CAAuB;gBAEzB,UAAU,EAAE,UAAU,EAAmB,aAAa,EAAE,iBAAiB;IAKrF;;OAEG;IACG,IAAI;
|
1
|
+
{"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../../src/dbos-runtime/runtime.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAa5D,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,qBAAa,WAAW;IAIc,OAAO,CAAC,QAAQ,CAAC,aAAa;IAHlE,OAAO,CAAC,QAAQ,CAAe;IAC/B,OAAO,CAAC,MAAM,CAAuB;gBAEzB,UAAU,EAAE,UAAU,EAAmB,aAAa,EAAE,iBAAiB;IAKrF;;OAEG;IACG,IAAI;IASV;;OAEG;WACU,WAAW,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC;IAmB/D;;OAEG;IACH,WAAW;IASX;;OAEG;IACG,OAAO;CAId"}
|
@@ -46,34 +46,33 @@ class DBOSRuntime {
|
|
46
46
|
* Initialize the runtime by loading user functions and initializing the workflow executor object
|
47
47
|
*/
|
48
48
|
async init() {
|
49
|
-
const
|
50
|
-
if (
|
49
|
+
const classes = await DBOSRuntime.loadClasses(this.runtimeConfig.entrypoint);
|
50
|
+
if (classes.length === 0) {
|
51
51
|
this.dbosExec.logger.error("operations not found");
|
52
52
|
throw new error_1.DBOSError("operations not found");
|
53
53
|
}
|
54
|
-
const classes = [];
|
55
|
-
for (const key in exports) {
|
56
|
-
if ((0, lodash_1.isObject)(exports[key])) {
|
57
|
-
classes.push(exports[key]);
|
58
|
-
this.dbosExec.logger.debug(`Loaded class: ${key}`);
|
59
|
-
}
|
60
|
-
}
|
61
54
|
await this.dbosExec.init(...classes);
|
62
55
|
}
|
63
56
|
/**
|
64
57
|
* Load an application's workflow functions, assumed to be in src/operations.ts (which is compiled to dist/operations.js).
|
65
58
|
*/
|
66
|
-
|
67
|
-
const entrypoint = this.runtimeConfig.entrypoint;
|
59
|
+
static async loadClasses(entrypoint) {
|
68
60
|
const operations = node_path_1.default.isAbsolute(entrypoint) ? entrypoint : node_path_1.default.join(process.cwd(), entrypoint);
|
61
|
+
let exports;
|
69
62
|
if (fs.existsSync(operations)) {
|
70
63
|
/* eslint-disable-next-line @typescript-eslint/no-var-requires */
|
71
|
-
|
64
|
+
exports = (await Promise.resolve(`${operations}`).then(s => __importStar(require(s))));
|
72
65
|
}
|
73
66
|
else {
|
74
|
-
|
75
|
-
|
67
|
+
throw new error_1.DBOSError(`Failed to load operations from the entrypoint ${entrypoint}`);
|
68
|
+
}
|
69
|
+
const classes = [];
|
70
|
+
for (const key in exports) {
|
71
|
+
if ((0, lodash_1.isObject)(exports[key])) {
|
72
|
+
classes.push(exports[key]);
|
73
|
+
}
|
76
74
|
}
|
75
|
+
return classes;
|
77
76
|
}
|
78
77
|
/**
|
79
78
|
* Start an HTTP server hosting an application's functions.
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"runtime.js","sourceRoot":"","sources":["../../../src/dbos-runtime/runtime.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oDAA4D;AAC5D,iDAAsD;AACtD,uCAAyB;AACzB,mCAAkC;AAElC,oCAAqC;AACrC,0DAA6B;AAY7B,MAAa,WAAW;IAI+B;IAH7C,QAAQ,CAAe;IACvB,MAAM,GAAkB,IAAI,CAAC;IAErC,YAAY,UAAsB,EAAmB,aAAgC;QAAhC,kBAAa,GAAb,aAAa,CAAmB;QACnF,gCAAgC;QAChC,IAAI,CAAC,QAAQ,GAAG,IAAI,4BAAY,CAAC,UAAU,CAAC,CAAC;IAC/C,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,IAAI;QACR,MAAM,OAAO,GAAG,MAAM,
|
1
|
+
{"version":3,"file":"runtime.js","sourceRoot":"","sources":["../../../src/dbos-runtime/runtime.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,oDAA4D;AAC5D,iDAAsD;AACtD,uCAAyB;AACzB,mCAAkC;AAElC,oCAAqC;AACrC,0DAA6B;AAY7B,MAAa,WAAW;IAI+B;IAH7C,QAAQ,CAAe;IACvB,MAAM,GAAkB,IAAI,CAAC;IAErC,YAAY,UAAsB,EAAmB,aAAgC;QAAhC,kBAAa,GAAb,aAAa,CAAmB;QACnF,gCAAgC;QAChC,IAAI,CAAC,QAAQ,GAAG,IAAI,4BAAY,CAAC,UAAU,CAAC,CAAC;IAC/C,CAAC;IAED;;OAEG;IACH,KAAK,CAAC,IAAI;QACR,MAAM,OAAO,GAAG,MAAM,WAAW,CAAC,WAAW,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;QAC7E,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE;YACxB,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,sBAAsB,CAAC,CAAC;YACnD,MAAM,IAAI,iBAAS,CAAC,s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AE,OAAO,EAAE,CAAC;IACjC,CAAC;CACF;AA9DD,kCA8DC"}
|
@@ -22,7 +22,7 @@ class WorkflowContextDebug extends context_1.DBOSContextImpl {
|
|
22
22
|
this.workflowConfig = workflowConfig;
|
23
23
|
this.workflowUUID = workflowUUID;
|
24
24
|
this.#dbosExec = dbosExec;
|
25
|
-
this.isTempWorkflow =
|
25
|
+
this.isTempWorkflow = dbos_executor_1.DBOSExecutor.tempWorkflowName === workflowName;
|
26
26
|
if (dbosExec.config.application) {
|
27
27
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
28
28
|
this.applicationConfig = dbosExec.config.application;
|
@@ -64,7 +64,7 @@ class WorkflowContextDebug extends context_1.DBOSContextImpl {
|
|
64
64
|
};
|
65
65
|
// Send a signal to the debug proxy.
|
66
66
|
// TODO: use the real command once the proxy is fully implemented.
|
67
|
-
await this.#dbosExec.userDatabase.queryWithClient(client, `--proxy:${res.txn_id}`);
|
67
|
+
await this.#dbosExec.userDatabase.queryWithClient(client, `--proxy:${res.txn_id ?? ''}:${res.txn_snapshot}`);
|
68
68
|
return res;
|
69
69
|
}
|
70
70
|
/**
|
@@ -72,8 +72,8 @@ class WorkflowContextDebug extends context_1.DBOSContextImpl {
|
|
72
72
|
* It connects to a debug proxy and everything should be read-only.
|
73
73
|
*/
|
74
74
|
async transaction(txn, ...args) {
|
75
|
-
const
|
76
|
-
if (
|
75
|
+
const txnInfo = this.#dbosExec.transactionInfoMap.get(txn.name);
|
76
|
+
if (txnInfo === undefined) {
|
77
77
|
throw new error_1.DBOSDebuggerError(`Transaction ${txn.name} not registered!`);
|
78
78
|
}
|
79
79
|
// const readOnly = true; // TODO: eventually, this transaction must be read-only.
|
@@ -88,14 +88,14 @@ class WorkflowContextDebug extends context_1.DBOSContextImpl {
|
|
88
88
|
const result = await txn(tCtxt, ...args);
|
89
89
|
return result;
|
90
90
|
};
|
91
|
-
const result = await this.#dbosExec.userDatabase.transaction(wrappedTransaction, config);
|
91
|
+
const result = await this.#dbosExec.userDatabase.transaction(wrappedTransaction, txnInfo.config);
|
92
92
|
if (JSON.stringify(check.output) !== JSON.stringify(result)) {
|
93
93
|
this.logger.error(`Detected different transaction output than the original one!\n Expected: ${JSON.stringify(result)}\n Received: ${JSON.stringify(check.output)}`);
|
94
94
|
}
|
95
95
|
return check.output; // Always return the recorded result.
|
96
96
|
}
|
97
97
|
async external(commFn, ..._args) {
|
98
|
-
const commConfig = this.#dbosExec.
|
98
|
+
const commConfig = this.#dbosExec.communicatorInfoMap.get(commFn.name);
|
99
99
|
if (commConfig === undefined) {
|
100
100
|
throw new error_1.DBOSDebuggerError(`Communicator ${commFn.name} not registered!`);
|
101
101
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"debug_workflow.js","sourceRoot":"","sources":["../../../src/debugger/debug_workflow.ts"],"names":[],"mappings":";;;AAAA,uDAAuD;AACvD,oDAAoE;AAEpE,gDAAqE;AAErE,oCAA4C;AAC5C,qDAAmD;AAInD,wCAA6C;AAC7C,8CAAwD;AASxD;;GAEG;AACH,MAAa,oBAAqB,SAAQ,yBAAe;IAKoD;IAJ3G,UAAU,GAAW,CAAC,CAAC;IACd,SAAS,CAAC;IACV,cAAc,CAAU;IAEjC,YAAY,QAAsB,EAAE,SAAsC,EAAE,YAAoB,EAAW,cAA8B,EAAE,YAAoB;QAC7J,MAAM,IAAI,GAAG,QAAQ,CAAC,MAAM,CAAC,SAAS,CAAC,YAAY,EAAE,EAAE,YAAY,EAAE,YAAY,EAAE,EAAE,SAAS,EAAE,IAAI,CAAC,CAAC;QACtG,KAAK,CAAC,YAAY,EAAE,IAAI,EAAE,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;QAFmD,mBAAc,GAAd,cAAc,CAAgB;QAGvI,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;QACjC,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC;QAC1B,IAAI,CAAC,cAAc,GAAG,
|
1
|
+
{"version":3,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I,oBAAoB,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,EAAE,UAAU,EAAE,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;IAC5G,CAAC;CACF;AA5KD,oDA4KC;AAED;;GAEG;AACH,MAAM,oBAAoB;IACH;IAAyC;IAA+B;IAA6B;IAA1H,YAAqB,cAA8B,EAAW,YAAoB,EAAW,UAAkB,EAAW,gBAAwB;QAA7H,mBAAc,GAAd,cAAc,CAAgB;QAAW,iBAAY,GAAZ,YAAY,CAAQ;QAAW,eAAU,GAAV,UAAU,CAAQ;QAAW,qBAAgB,GAAhB,gBAAgB,CAAQ;IAAG,CAAC;IAEtJ,eAAe;QACb,OAAO,IAAI,CAAC,YAAY,CAAC;IAC3B,CAAC;IAED,KAAK,CAAC,SAAS;QACb,4BAA4B;QAC5B,MAAM,KAAK,GAAqC,MAAM,IAAI,CAAC,cAAc,CAAC,oBAAoB,CAAwB,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,gBAAgB,CAAC,CAAC;QAC9J,IAAI,KAAK,KAAK,wBAAQ,EAAE;YACtB,MAAM,IAAI,yBAAiB,CAAC,uEAAuE,CAAC,CAAC;SACtG;QACD,OAAO,KAA8B,CAAC;IACxC,CAAC;IAED,KAAK,CAAC,SAAS;QACb,OAAO,MAAM,IAAI,CAAC,cAAc,CAAC,iBAAiB,CAAI,IAAI,CAAC,YAAY,CAAC,CAAC;IAC3E,CAAC;CACF"}
|
@@ -5,7 +5,7 @@
|
|
5
5
|
import Koa from 'koa';
|
6
6
|
import Router from '@koa/router';
|
7
7
|
import { DBOSExecutor } from "../dbos-executor";
|
8
|
-
import { Logger } from "
|
8
|
+
import { GlobalLogger as Logger } from "../telemetry/logs";
|
9
9
|
export declare const WorkflowUUIDHeader = "dbos-workflowuuid";
|
10
10
|
export declare const WorkflowRecoveryUrl = "/dbos-workflow-recovery";
|
11
11
|
export declare class DBOSHttpServer {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/httpServer/server.ts"],"names":[],"mappings":";;;;AAAA,OAAO,GAAG,MAAM,KAAK,CAAC;AACtB,OAAO,MAAM,MAAM,aAAa,CAAC;AAkBjC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,
|
1
|
+
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/httpServer/server.ts"],"names":[],"mappings":";;;;AAAA,OAAO,GAAG,MAAM,KAAK,CAAC;AACtB,OAAO,MAAM,MAAM,aAAa,CAAC;AAkBjC,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,YAAY,IAAI,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAK3D,eAAO,MAAM,kBAAkB,sBAAsB,CAAC;AACtD,eAAO,MAAM,mBAAmB,4BAA4B,CAAA;AAE5D,qBAAa,cAAc;IAUb,QAAQ,CAAC,QAAQ,EAAE,YAAY;IAT3C,QAAQ,CAAC,GAAG,EAAE,GAAG,CAAC;IAClB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB;;;;OAIG;gBACkB,QAAQ,EAAE,YAAY,EAAE,MAAM,GAAE;QAAE,GAAG,CAAC,EAAE,GAAG,CAAC;QAAC,MAAM,CAAC,EAAE,MAAM,CAAA;KAAO;IAuBxF;;;OAGG;IACH,MAAM,CAAC,IAAI,EAAE,MAAM;IAOnB;;;OAGG;IACH,MAAM,CAAC,wBAAwB,CAAC,QAAQ,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM;IAmBtE;;OAEG;IACH,MAAM,CAAC,0BAA0B,CAAC,QAAQ,EAAE,YAAY,EAAE,MAAM,EAAE,MAAM;CAwKzE"}
|
@@ -30,4 +30,8 @@ export declare class TypeParser {
|
|
30
30
|
constructor(program: ts.Program);
|
31
31
|
parse(): readonly ClassInfo[] | undefined;
|
32
32
|
}
|
33
|
+
export declare function findPackageInfo(entrypoints: string[]): Promise<{
|
34
|
+
name: string;
|
35
|
+
version: string;
|
36
|
+
}>;
|
33
37
|
//# sourceMappingURL=TypeParser.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"TypeParser.d.ts","sourceRoot":"","sources":["../../../src/staticAnalysis/TypeParser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,YAAY,CAAC;AAK5B,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,IAAI,EAAE,EAAE,CAAC,gBAAgB,CAAC;IACnC,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,UAAU,EAAE,SAAS,aAAa,EAAE,CAAC;IAC9C,QAAQ,CAAC,OAAO,EAAE,SAAS,UAAU,EAAE,CAAC;CACzC;AAED,MAAM,WAAW,UAAU;IACzB,QAAQ,CAAC,IAAI,EAAE,EAAE,CAAC,iBAAiB,CAAC;IACpC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,UAAU,EAAE,SAAS,aAAa,EAAE,CAAC;IAC9C,QAAQ,CAAC,UAAU,EAAE,SAAS,aAAa,EAAE,CAAC;CAC/C;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,IAAI,EAAE,EAAE,CAAC,oBAAoB,CAAC;IACvC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,UAAU,EAAE,SAAS,aAAa,EAAE,CAAC;IAC9C,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;CAC5B;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,EAAE,CAAC,SAAS,CAAC;IACnB,UAAU,EAAE,EAAE,CAAC,UAAU,CAAC;IAC1B,IAAI,EAAE,SAAS,EAAE,CAAC,UAAU,EAAE,CAAC;IAC/B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAOD,qBAAa,UAAU;;IAIrB,IAAI,KAAK,6BAAgC;gBAE7B,OAAO,EAAE,EAAE,CAAC,OAAO;IAK/B,KAAK,IAAI,SAAS,SAAS,EAAE,GAAG,SAAS;CA2F1C;AAED,wBAAsB,eAAe,CAAC,WAAW,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC,CA4BvG"}
|
@@ -3,9 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
4
|
};
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.TypeParser = void 0;
|
6
|
+
exports.findPackageInfo = exports.TypeParser = void 0;
|
7
7
|
const typescript_1 = __importDefault(require("typescript"));
|
8
8
|
const tsDiagUtil_1 = require("./tsDiagUtil");
|
9
|
+
const node_path_1 = __importDefault(require("node:path"));
|
10
|
+
const promises_1 = __importDefault(require("node:fs/promises"));
|
9
11
|
function isStaticMethod(node) {
|
10
12
|
const mods = node.modifiers ?? [];
|
11
13
|
return mods.some(m => m.kind === typescript_1.default.SyntaxKind.StaticKeyword);
|
@@ -101,4 +103,35 @@ class TypeParser {
|
|
101
103
|
}
|
102
104
|
}
|
103
105
|
exports.TypeParser = TypeParser;
|
106
|
+
async function findPackageInfo(entrypoints) {
|
107
|
+
for (const entrypoint of entrypoints) {
|
108
|
+
let dirname = node_path_1.default.dirname(entrypoint);
|
109
|
+
while (dirname !== '/') {
|
110
|
+
try {
|
111
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
112
|
+
const packageJson = JSON.parse(await promises_1.default.readFile(node_path_1.default.join(dirname, 'package.json'), { encoding: 'utf-8' }));
|
113
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
114
|
+
const name = packageJson.name ?? "unknown";
|
115
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
116
|
+
const version = packageJson.version;
|
117
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
118
|
+
const isPrivate = packageJson.private ?? false;
|
119
|
+
return {
|
120
|
+
name,
|
121
|
+
version: version
|
122
|
+
? version
|
123
|
+
: isPrivate ? "private" : "unknown"
|
124
|
+
};
|
125
|
+
}
|
126
|
+
catch (error) {
|
127
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-explicit-any
|
128
|
+
if (error.code !== 'ENOENT')
|
129
|
+
throw error;
|
130
|
+
}
|
131
|
+
dirname = node_path_1.default.dirname(dirname);
|
132
|
+
}
|
133
|
+
}
|
134
|
+
return { name: "unknown", version: "unknown" };
|
135
|
+
}
|
136
|
+
exports.findPackageInfo = findPackageInfo;
|
104
137
|
//# sourceMappingURL=TypeParser.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"TypeParser.js","sourceRoot":"","sources":["../../../src/staticAnalysis/TypeParser.ts"],"names":[],"mappings":";;;;;;AAAA,4DAA4B;AAC5B,6CAAgE;AAChE,0DAA6B;AAC7B,gEAAkC;AA+BlC,SAAS,cAAc,CAAC,IAA0B;IAChD,MAAM,IAAI,GAAG,IAAI,CAAC,SAAS,IAAI,EAAE,CAAC;IAClC,OAAO,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,oBAAE,CAAC,UAAU,CAAC,aAAa,CAAC,CAAC;AAChE,CAAC;AAED,MAAa,UAAU;IACZ,QAAQ,CAAa;IACrB,QAAQ,CAAiB;IACzB,MAAM,GAAG,IAAI,iCAAoB,EAAE,CAAC;IAC7C,IAAI,KAAK,KAAK,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC;IAEzC,YAAY,OAAmB;QAC7B,IAAI,CAAC,QAAQ,GAAG,OAAO,CAAC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AE,EAAE,CAAC,UAAU,GAAG,cAAc,GAAG,SAAS;CAwErE;AAED,KAAK,cAAc,GAAG,OAAO,CAAC,QAAQ,CAAC,oBAAoB,EAAE,QAAQ,CAAC,oBAAoB,CAAC,CAAC;AAE5F,wBAAsB,eAAe,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC,QAAQ,GAAG,SAAS,CAAC,CAchG"}
|
@@ -8,8 +8,6 @@ const typescript_1 = __importDefault(require("typescript"));
|
|
8
8
|
const TypeParser_1 = require("./TypeParser");
|
9
9
|
const handler_1 = require("../httpServer/handler");
|
10
10
|
const ts_json_schema_generator_1 = require("ts-json-schema-generator");
|
11
|
-
const node_path_1 = __importDefault(require("node:path"));
|
12
|
-
const promises_1 = __importDefault(require("node:fs/promises"));
|
13
11
|
const tsDiagUtil_1 = require("./tsDiagUtil");
|
14
12
|
function isValid(value) { return value !== undefined; }
|
15
13
|
// ts-json-schema-generator does not support BigInt, so OpenApiGenerator needs a custom type, formatter and parser for it
|
@@ -550,34 +548,6 @@ class OpenApiGenerator {
|
|
550
548
|
}
|
551
549
|
}
|
552
550
|
exports.OpenApiGenerator = OpenApiGenerator;
|
553
|
-
async function findPackageInfo(entrypoint) {
|
554
|
-
let dirname = node_path_1.default.dirname(entrypoint);
|
555
|
-
while (dirname !== '/') {
|
556
|
-
try {
|
557
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
|
558
|
-
const packageJson = JSON.parse(await promises_1.default.readFile(node_path_1.default.join(dirname, 'package.json'), { encoding: 'utf-8' }));
|
559
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
560
|
-
const name = packageJson.name ?? "unknown";
|
561
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
562
|
-
const version = packageJson.version;
|
563
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
564
|
-
const isPrivate = packageJson.private ?? false;
|
565
|
-
return {
|
566
|
-
name,
|
567
|
-
version: version
|
568
|
-
? version
|
569
|
-
: isPrivate ? "private" : "unknown"
|
570
|
-
};
|
571
|
-
}
|
572
|
-
catch (error) {
|
573
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-explicit-any
|
574
|
-
if (error.code !== 'ENOENT')
|
575
|
-
throw error;
|
576
|
-
}
|
577
|
-
dirname = node_path_1.default.dirname(dirname);
|
578
|
-
}
|
579
|
-
return { name: "unknown", version: "unknown" };
|
580
|
-
}
|
581
551
|
async function generateOpenApi(entrypoint) {
|
582
552
|
const program = typescript_1.default.createProgram([entrypoint], {});
|
583
553
|
const parser = new TypeParser_1.TypeParser(program);
|
@@ -585,7 +555,7 @@ async function generateOpenApi(entrypoint) {
|
|
585
555
|
(0, tsDiagUtil_1.logDiagnostics)(parser.diags);
|
586
556
|
if (!classes || classes.length === 0)
|
587
557
|
return undefined;
|
588
|
-
const { name, version } = await findPackageInfo(entrypoint);
|
558
|
+
const { name, version } = await (0, TypeParser_1.findPackageInfo)([entrypoint]);
|
589
559
|
const generator = new OpenApiGenerator(program);
|
590
560
|
const openapi = generator.generate(classes, name, version);
|
591
561
|
(0, tsDiagUtil_1.logDiagnostics)(generator.diags);
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"openApi.js","sourceRoot":"","sources":["../../../src/staticAnalysis/openApi.ts"],"names":[],"mappings":";;;;;;AAAA,4DAA4B;AAC5B,6CAOsB;AAEtB,mDAA6D;AAE7D,uEAakC;AAGlC,6CAAgF;AAEhF,SAAS,OAAO,CAAI,KAAoB,IAAgB,OAAO,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC;AAIrF,yHAAyH;AACzH,MAAM,UAAW,SAAQ,wCAAa;IACpC,KAAK,KAAa,OAAO,SAAS,CAAC,CAAC,CAAC;CACtC;AAED,MAAM,mBAAmB;IACvB,YAAY,CAAC,IAAa;QACxB,OAAO,IAAI,CAAC,IAAI,KAAK,oBAAE,CAAC,UAAU,CAAC,aAAa,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MAAM,OAAO,GAAG,SAAS,CAAC,QAAQ,CAAC,OAAO,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IAC3D,IAAA,2BAAc,EAAC,SAAS,CAAC,KAAK,CAAC,CAAC;IAChC,OAAO,OAAO,CAAC;AACjB,CAAC;AAdD,0CAcC"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"tsDiagUtil.d.ts","sourceRoot":"","sources":["../../../src/staticAnalysis/tsDiagUtil.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,YAAY,CAAC;AAIjC,MAAM,WAAW,iBAAiB;IAChC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,EAAE,CAAC,IAAI,CAAC;IACf,QAAQ,CAAC,EAAE,EAAE,CAAC,kBAAkB,CAAC;CAClC;AAED,wBAAgB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,iBAAiB,GAAG,EAAE,CAAC,UAAU,CAchG;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,UAAU,EAAE,GAAG,CAAC,GAAG,SAAS,CAEtF;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,SAAS,EAAE,CAAC,UAAU,EAAE,GAAG,IAAI,CAYpE;AAED,qBAAa,oBAAoB;;IAE/B,IAAI,KAAK,6BAAsD;IAE/D,KAAK,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,EAAE,CAAC,IAAI,GAAG,IAAI;IAI5C,IAAI,CAAC,OAAO,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,EAAE,CAAC,IAAI,GAAG,IAAI;CAG5C"}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"tsDiagUtil.js","sourceRoot":"","sources":["../../../src/staticAnalysis/tsDiagUtil.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;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AAC,QAAgB,EAAE,EAAE,CAAC,EAAE,CAAC,GAAG,CAAC,yBAAyB;gBAC1E,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,WAAW,EAAE;SACtC,CAAA;QAED,MAAM,IAAI,GAAG,EAAE,CAAC,oCAAoC,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;QACxE,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;KACnB;AACH,CAAC;AAZD,wCAYC;AAED,MAAa,oBAAoB;IACtB,MAAM,GAAG,IAAI,KAAK,EAAiB,CAAC;IAC7C,IAAI,KAAK,KAAK,OAAO,IAAI,CAAC,MAAkC,CAAC,CAAC,CAAC;IAE/D,KAAK,CAAC,OAAe,EAAE,IAAc;QACnC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;IACxD,CAAC;IAED,IAAI,CAAC,OAAe,EAAE,IAAc;QAClC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,CAAC,kBAAkB,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC;IACjG,CAAC;CACF;AAXD,oDAWC"}
|
@@ -2,16 +2,15 @@ import { DBOSNull } from "./dbos-executor";
|
|
2
2
|
import { Pool, PoolClient, PoolConfig } from "pg";
|
3
3
|
import { WorkflowStatus } from "./workflow";
|
4
4
|
import { HTTPRequest } from "./context";
|
5
|
-
import { Logger } from "
|
6
|
-
export declare const DBOSExecutorIDHeader = "dbos-executor-id";
|
5
|
+
import { GlobalLogger as Logger } from "./telemetry/logs";
|
7
6
|
export interface SystemDatabase {
|
8
7
|
init(): Promise<void>;
|
9
8
|
destroy(): Promise<void>;
|
10
9
|
checkWorkflowOutput<R>(workflowUUID: string): Promise<DBOSNull | R>;
|
11
|
-
initWorkflowStatus<T extends any[]>(
|
12
|
-
bufferWorkflowOutput
|
10
|
+
initWorkflowStatus<T extends any[]>(bufferedStatus: WorkflowStatusInternal, args: T): Promise<T>;
|
11
|
+
bufferWorkflowOutput(workflowUUID: string, status: WorkflowStatusInternal): void;
|
13
12
|
flushWorkflowStatusBuffer(): Promise<Array<string>>;
|
14
|
-
recordWorkflowError(workflowUUID: string,
|
13
|
+
recordWorkflowError(workflowUUID: string, status: WorkflowStatusInternal): Promise<void>;
|
15
14
|
getPendingWorkflows(executorID: string): Promise<Array<string>>;
|
16
15
|
setWorkflowInputs<T extends any[]>(workflowUUID: string, args: T): Promise<void>;
|
17
16
|
getWorkflowInputs<T extends any[]>(workflowUUID: string): Promise<T | null>;
|
@@ -25,6 +24,18 @@ export interface SystemDatabase {
|
|
25
24
|
setEvent<T extends NonNullable<any>>(workflowUUID: string, functionID: number, key: string, value: T): Promise<void>;
|
26
25
|
getEvent<T extends NonNullable<any>>(workflowUUID: string, key: string, timeoutSeconds: number, callerUUID?: string, functionID?: number): Promise<T | null>;
|
27
26
|
}
|
27
|
+
export interface WorkflowStatusInternal {
|
28
|
+
workflowUUID: string;
|
29
|
+
status: string;
|
30
|
+
name: string;
|
31
|
+
authenticatedUser: string;
|
32
|
+
output: unknown;
|
33
|
+
error: string;
|
34
|
+
assumedRole: string;
|
35
|
+
authenticatedRoles: string[];
|
36
|
+
request: HTTPRequest;
|
37
|
+
executorID: string;
|
38
|
+
}
|
28
39
|
export declare class PostgresSystemDatabase implements SystemDatabase {
|
29
40
|
readonly pgPoolConfig: PoolConfig;
|
30
41
|
readonly systemDatabaseName: string;
|
@@ -33,18 +44,18 @@ export declare class PostgresSystemDatabase implements SystemDatabase {
|
|
33
44
|
notificationsClient: PoolClient | null;
|
34
45
|
readonly notificationsMap: Record<string, () => void>;
|
35
46
|
readonly workflowEventsMap: Record<string, () => void>;
|
36
|
-
readonly workflowStatusBuffer: Map<string,
|
47
|
+
readonly workflowStatusBuffer: Map<string, WorkflowStatusInternal>;
|
37
48
|
constructor(pgPoolConfig: PoolConfig, systemDatabaseName: string, logger: Logger);
|
38
49
|
init(): Promise<void>;
|
39
50
|
destroy(): Promise<void>;
|
40
51
|
checkWorkflowOutput<R>(workflowUUID: string): Promise<DBOSNull | R>;
|
41
|
-
initWorkflowStatus<T extends any[]>(
|
42
|
-
bufferWorkflowOutput
|
52
|
+
initWorkflowStatus<T extends any[]>(initStatus: WorkflowStatusInternal, args: T): Promise<T>;
|
53
|
+
bufferWorkflowOutput(workflowUUID: string, status: WorkflowStatusInternal): void;
|
43
54
|
/**
|
44
55
|
* Flush the workflow output buffer to the database.
|
45
56
|
*/
|
46
57
|
flushWorkflowStatusBuffer(): Promise<string[]>;
|
47
|
-
recordWorkflowError(workflowUUID: string,
|
58
|
+
recordWorkflowError(workflowUUID: string, status: WorkflowStatusInternal): Promise<void>;
|
48
59
|
getPendingWorkflows(executorID: string): Promise<Array<string>>;
|
49
60
|
setWorkflowInputs<T extends any[]>(workflowUUID: string, args: T): Promise<void>;
|
50
61
|
getWorkflowInputs<T extends any[]>(workflowUUID: string): Promise<T | null>;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"system_database.d.ts","sourceRoot":"","sources":["../../src/system_database.ts"],"names":[],"mappings":"AAGA,OAAO,EAA0B,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AACnE,OAAO,EAAiB,IAAI,EAAE,UAAU,EAAgB,UAAU,EAAU,MAAM,IAAI,CAAC;AAEvF,OAAO,EAAgB,cAAc,EAAE,MAAM,YAAY,CAAC;AAG1D,OAAO,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AACxC,OAAO,EAAE,
|
1
|
+
{"version":3,"file":"system_database.d.ts","sourceRoot":"","sources":["../../src/system_database.ts"],"names":[],"mappings":"AAGA,OAAO,EAA0B,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AACnE,OAAO,EAAiB,IAAI,EAAE,UAAU,EAAgB,UAAU,EAAU,MAAM,IAAI,CAAC;AAEvF,OAAO,EAAg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