diff --git a/package-lock.json b/package-lock.json index bc62acc305..4378dc5bf2 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,6 +19,7 @@ "@koa/router": "^12.0.0", "@ndhoule/extend": "^2.0.0", "@pyroscope/nodejs": "^0.2.6", + "@rudderstack/workflow-engine": "^0.5.7", "ajv": "^8.12.0", "ajv-draft-04": "^1.0.0", "ajv-formats": "^2.1.1", @@ -58,7 +59,6 @@ "prom-client": "^14.2.0", "qs": "^6.11.1", "rudder-transformer-cdk": "^1.4.11", - "rudder-workflow-engine": "^0.4.7", "set-value": "^4.1.0", "sha256": "^0.2.0", "stacktrace-parser": "^0.1.10", @@ -3825,6 +3825,49 @@ "node": ">= 8" } }, + "node_modules/@rudderstack/json-template-engine": { + "version": "0.5.5", + "resolved": "https://registry.npmjs.org/@rudderstack/json-template-engine/-/json-template-engine-0.5.5.tgz", + "integrity": "sha512-p3HdTqgZiJjjZmjaHN2paa1e87ifGE5UjkA4zdvge4bBzJbKKMQNWqRg6I96SwoA+hsxNkW/f9R83SPLU9t7LA==" + }, + "node_modules/@rudderstack/workflow-engine": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/@rudderstack/workflow-engine/-/workflow-engine-0.5.7.tgz", + "integrity": "sha512-qR4eSiSFgYdOMtldR0rJ5kLGiTfnyufDfkMHNXFybxPb3jpjxBEGapj2lRiiTiRPgSUef7vuKyJ8BzY/VR4noA==", + "dependencies": { + "@aws-crypto/sha256-js": "^4.0.0", + "@rudderstack/json-template-engine": "^0.5.5", + "js-yaml": "^4.1.0", + "jsonata": "^2.0.3", + "lodash": "^4.17.21", + "object-sizeof": "^2.6.3" + } + }, + "node_modules/@rudderstack/workflow-engine/node_modules/@aws-crypto/sha256-js": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-4.0.0.tgz", + "integrity": "sha512-MHGJyjE7TX9aaqXj7zk2ppnFUOhaDs5sP+HtNS0evOxn72c+5njUmyJmpGd7TfyoDznZlHMmdo/xGUdu2NIjNQ==", + "dependencies": { + "@aws-crypto/util": "^4.0.0", + "@aws-sdk/types": "^3.222.0", + "tslib": "^1.11.1" + } + }, + "node_modules/@rudderstack/workflow-engine/node_modules/@aws-crypto/util": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-4.0.0.tgz", + "integrity": "sha512-2EnmPy2gsFZ6m8bwUQN4jq+IyXV3quHAcwPOS6ZA3k+geujiqI8aRokO2kFJe+idJ/P3v4qWI186rVMo0+zLDQ==", + "dependencies": { + "@aws-sdk/types": "^3.222.0", + "@aws-sdk/util-utf8-browser": "^3.0.0", + "tslib": "^1.11.1" + } + }, + "node_modules/@rudderstack/workflow-engine/node_modules/tslib": { + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", + "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" + }, "node_modules/@sideway/address": { "version": "4.1.4", "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", @@ -14459,6 +14502,37 @@ "node": ">= 0.4" } }, + "node_modules/object-sizeof": { + "version": "2.6.3", + "resolved": "https://registry.npmjs.org/object-sizeof/-/object-sizeof-2.6.3.tgz", + "integrity": "sha512-GNkVRrLh11Qr5BGr73dwwPE200/78QG2rbx30cnXPnMvt7UuttH4Dup5t+LtcQhARkg8Hbr0c8Kiz52+CFxYmw==", + "dependencies": { + "buffer": "^6.0.3" + } + }, + "node_modules/object-sizeof/node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, "node_modules/object.assign": { "version": "4.1.4", "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", @@ -16117,11 +16191,6 @@ "node": ">=12.0" } }, - "node_modules/rudder-json-template-engine": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/rudder-json-template-engine/-/rudder-json-template-engine-0.5.1.tgz", - "integrity": "sha512-D8zCcTXbhbFd2EhDmmgZKxw5uky6+DfikV/EW8I8HWdutMiyzdxgVMyH1dPo3feLgj3/0g2WNO9t4iPaegw4PQ==" - }, "node_modules/rudder-transformer-cdk": { "version": "1.4.11", "resolved": "https://registry.npmjs.org/rudder-transformer-cdk/-/rudder-transformer-cdk-1.4.11.tgz", @@ -16139,43 +16208,6 @@ "winston": "^3.8.1" } }, - "node_modules/rudder-workflow-engine": { - "version": "0.4.7", - "resolved": "https://registry.npmjs.org/rudder-workflow-engine/-/rudder-workflow-engine-0.4.7.tgz", - "integrity": "sha512-USJ/h4XGxtUmAhaTJgtz1MrICpiju6GTubaFyPS+5hgpjdIsZx/iOOishjrNcOrwHvxcfblccA8wv5JTC8eSpg==", - "dependencies": { - "@aws-crypto/sha256-js": "^4.0.0", - "js-yaml": "^4.1.0", - "jsonata": "^2.0.3", - "lodash": "^4.17.21", - "rudder-json-template-engine": "^0.5.1" - } - }, - "node_modules/rudder-workflow-engine/node_modules/@aws-crypto/sha256-js": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/sha256-js/-/sha256-js-4.0.0.tgz", - "integrity": "sha512-MHGJyjE7TX9aaqXj7zk2ppnFUOhaDs5sP+HtNS0evOxn72c+5njUmyJmpGd7TfyoDznZlHMmdo/xGUdu2NIjNQ==", - "dependencies": { - "@aws-crypto/util": "^4.0.0", - "@aws-sdk/types": "^3.222.0", - "tslib": "^1.11.1" - } - }, - "node_modules/rudder-workflow-engine/node_modules/@aws-crypto/util": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/@aws-crypto/util/-/util-4.0.0.tgz", - "integrity": "sha512-2EnmPy2gsFZ6m8bwUQN4jq+IyXV3quHAcwPOS6ZA3k+geujiqI8aRokO2kFJe+idJ/P3v4qWI186rVMo0+zLDQ==", - "dependencies": { - "@aws-sdk/types": "^3.222.0", - "@aws-sdk/util-utf8-browser": "^3.0.0", - "tslib": "^1.11.1" - } - }, - "node_modules/rudder-workflow-engine/node_modules/tslib": { - "version": "1.14.1", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", - "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==" - }, "node_modules/run-async": { "version": "2.4.1", "resolved": "https://registry.npmjs.org/run-async/-/run-async-2.4.1.tgz", diff --git a/package.json b/package.json index a0c8a5b1ec..ff5fd27f3f 100644 --- a/package.json +++ b/package.json @@ -60,6 +60,7 @@ "@koa/router": "^12.0.0", "@ndhoule/extend": "^2.0.0", "@pyroscope/nodejs": "^0.2.6", + "@rudderstack/workflow-engine": "^0.5.7", "ajv": "^8.12.0", "ajv-draft-04": "^1.0.0", "ajv-formats": "^2.1.1", @@ -99,7 +100,6 @@ "prom-client": "^14.2.0", "qs": "^6.11.1", "rudder-transformer-cdk": "^1.4.11", - "rudder-workflow-engine": "^0.4.7", "set-value": "^4.1.0", "sha256": "^0.2.0", "stacktrace-parser": "^0.1.10", diff --git a/src/cdk/v2/handler.ts b/src/cdk/v2/handler.ts index b4da9bc6bf..898e83f7b8 100644 --- a/src/cdk/v2/handler.ts +++ b/src/cdk/v2/handler.ts @@ -4,7 +4,7 @@ import { TemplateType, ExecutionBindings, StepOutput, -} from 'rudder-workflow-engine'; +} from '@rudderstack/workflow-engine'; import tags from '../../v0/util/tags'; diff --git a/src/cdk/v2/utils.ts b/src/cdk/v2/utils.ts index 096e5b7679..9d46f3dace 100644 --- a/src/cdk/v2/utils.ts +++ b/src/cdk/v2/utils.ts @@ -1,6 +1,10 @@ import path from 'path'; import fs from 'fs/promises'; -import { WorkflowExecutionError, WorkflowCreationError, StatusError } from 'rudder-workflow-engine'; +import { + WorkflowExecutionError, + WorkflowCreationError, + StatusError, +} from '@rudderstack/workflow-engine'; import logger from '../../logger'; import { generateErrorObject } from '../../v0/util'; import { PlatformError } from '../../v0/util/errorTypes';