@celonis/content-cli 0.13.4 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -6
- package/{api → commands/action-flows/action-flow}/action-flow-api.js +10 -9
- package/commands/{action-flow.command.js → action-flows/action-flow/action-flow-command.service.js} +11 -8
- package/{services/action-flow/action-flow-service.js → commands/action-flows/action-flow/action-flow.service.js} +12 -10
- package/commands/action-flows/module.js +88 -0
- package/commands/{skill.command.js → action-flows/skill/skill-command.service.js} +9 -11
- package/{content/factory/skill-manager.factory.js → commands/action-flows/skill/skill.manager-factory.js} +7 -4
- package/{content/manager → commands/action-flows/skill}/skill.manager.js +7 -4
- package/commands/analysis/analysis-bookmarks-command.service.js +39 -0
- package/{content/factory/analysis-bookmarks-manager.factory.js → commands/analysis/analysis-bookmarks.manager-factory.js} +7 -4
- package/{content/manager → commands/analysis}/analysis-bookmarks.manager.js +8 -5
- package/commands/analysis/module.js +52 -0
- package/commands/configuration-management/api/batch-import-export-api.js +84 -0
- package/{api → commands/configuration-management/api}/diff-api.js +8 -7
- package/commands/configuration-management/api/variable-assignment-candidates-api.js +41 -0
- package/{services/package-manager/batch-import-export-service.js → commands/configuration-management/batch-import-export.service.js} +43 -23
- package/commands/configuration-management/config-command.service.js +76 -0
- package/{services/package-manager/diff-service.js → commands/configuration-management/diff.service.js} +11 -8
- package/commands/configuration-management/module.js +102 -0
- package/{services/studio → commands/configuration-management}/studio.service.js +33 -24
- package/commands/{variable.command.js → configuration-management/variable-command.service.js} +10 -7
- package/{services/package-manager/variable-service.js → commands/configuration-management/variable.service.js} +36 -42
- package/commands/{ctp.command.js → cpm4/ctp-command.service.js} +11 -13
- package/{content/manager → commands/cpm4}/ctp.analysis.manager.js +3 -0
- package/{content/manager → commands/cpm4}/ctp.datamodel.manager.js +2 -2
- package/{content/factory/ctp-manager.factory.js → commands/cpm4/ctp.manager-factory.js} +9 -6
- package/{content/manager → commands/cpm4}/ctp.manager.js +6 -4
- package/commands/cpm4/module.js +46 -0
- package/commands/{connection.command.js → data-pipeline/connection/connection-command.service.js} +14 -11
- package/commands/data-pipeline/connection/connection.commands.js +65 -0
- package/{services → commands/data-pipeline}/connection/connection.service.js +18 -15
- package/{api → commands/data-pipeline/data-pool}/data-pool-api.js +14 -13
- package/commands/{data-pool.command.js → data-pipeline/data-pool/data-pool-command.service.js} +25 -23
- package/{content/factory → commands/data-pipeline/data-pool}/data-pool-manager.factory.js +9 -6
- package/{services → commands/data-pipeline}/data-pool/data-pool-service.js +13 -10
- package/commands/data-pipeline/data-pool/data-pool.commands.js +99 -0
- package/{content/manager → commands/data-pipeline/data-pool}/data-pool.manager.js +8 -9
- package/commands/data-pipeline/module.js +24 -0
- package/commands/profile/module.js +60 -0
- package/commands/profile/profile-command.service.js +94 -0
- package/{api → commands/studio/api}/asset-api.js +8 -7
- package/{api → commands/studio/api}/compute-pool-api.js +7 -6
- package/{api → commands/studio/api}/node-api.js +9 -8
- package/{api → commands/studio/api}/package-api.js +18 -17
- package/{api → commands/studio/api}/package-dependencies-api.js +12 -11
- package/{api → commands/studio/api}/space-api.js +10 -9
- package/commands/{analysis-bookmarks.command.js → studio/api/studio-variables-api.js} +18 -13
- package/commands/{asset.command.js → studio/command-service/asset-command.service.js} +21 -19
- package/commands/{package.command.js → studio/command-service/package-command.service.js} +22 -20
- package/commands/{space.command.js → studio/command-service/space-command.service.js} +9 -11
- package/commands/studio/command-service/widget.command.js +56 -0
- package/{content/factory/asset-manager.factory.js → commands/studio/manager/asset.manager-factory.js} +7 -4
- package/{content → commands/studio}/manager/asset.manager.js +8 -5
- package/{content/factory/package-manager.factory.js → commands/studio/manager/package.manager-factory.js} +7 -4
- package/{content → commands/studio}/manager/package.manager.js +9 -6
- package/{content/factory/space-manager.factory.js → commands/studio/manager/space.manager-factory.js} +6 -3
- package/{content → commands/studio}/manager/space.manager.js +7 -4
- package/{content/factory/widget-manager.factory.js → commands/studio/manager/widget.manager-factory.js} +8 -5
- package/{content → commands/studio}/manager/widget.manager.js +5 -5
- package/commands/studio/module.js +169 -0
- package/{services/package-manager → commands/studio/service}/asset-service.js +10 -9
- package/{services/package-manager/datamodel-service.js → commands/studio/service/data-model.service.js} +8 -6
- package/{services/package-manager/package-service.js → commands/studio/service/package.service.js} +59 -49
- package/{services/package-manager/space-service.js → commands/studio/service/space.service.js} +9 -9
- package/commands/studio/service/studio-variable.service.js +41 -0
- package/content-cli.js +69 -20
- package/core/command/cli-context.js +69 -0
- package/core/command/module-handler.js +200 -0
- package/core/http/base-api.js +115 -0
- package/{services/http-client-service.v2.js → core/http/http-client.js} +39 -24
- package/{services/context.service.js → core/http/http-shared/base.manager.helper.js} +6 -16
- package/{content/manager → core/http/http-shared}/base.manager.js +14 -21
- package/{services → core/profile}/profile.service.js +11 -5
- package/{validators → core/profile}/profile.validator.js +3 -3
- package/{services → core/utils}/file-service.js +2 -7
- package/core/utils/logger.js +102 -0
- package/{services → core/utils}/question.service.js +18 -7
- package/{util → core/utils}/version.js +1 -1
- package/lib/{api → commands/action-flows/action-flow}/action-flow-api.d.ts +4 -4
- package/lib/commands/{action-flow.command.d.ts → action-flows/action-flow/action-flow-command.service.d.ts} +4 -1
- package/lib/{services/action-flow/action-flow-service.d.ts → commands/action-flows/action-flow/action-flow.service.d.ts} +4 -4
- package/lib/commands/action-flows/module.d.ts +14 -0
- package/lib/commands/{skill.command.d.ts → action-flows/skill/skill-command.service.d.ts} +3 -2
- package/lib/commands/action-flows/skill/skill.manager-factory.d.ts +8 -0
- package/lib/{content/manager → commands/action-flows/skill}/skill.manager.d.ts +4 -2
- package/lib/commands/analysis/analysis-bookmarks-command.service.d.ts +7 -0
- package/lib/commands/analysis/analysis-bookmarks.manager-factory.d.ts +8 -0
- package/lib/{content/manager → commands/analysis}/analysis-bookmarks.manager.d.ts +4 -2
- package/lib/commands/analysis/module.d.ts +11 -0
- package/lib/{api → commands/configuration-management/api}/batch-import-export-api.d.ts +6 -5
- package/lib/{api → commands/configuration-management/api}/diff-api.d.ts +5 -5
- package/lib/commands/configuration-management/api/variable-assignment-candidates-api.d.ts +8 -0
- package/lib/{services/package-manager/batch-import-export-service.d.ts → commands/configuration-management/batch-import-export.service.d.ts} +8 -3
- package/lib/commands/{config.command.d.ts → configuration-management/config-command.service.d.ts} +8 -2
- package/lib/{services/package-manager/diff-service.d.ts → commands/configuration-management/diff.service.d.ts} +4 -3
- package/lib/{interfaces/package-export-transport.d.ts → commands/configuration-management/interfaces/package-export.interfaces.d.ts} +2 -2
- package/lib/{api/variable-assignment-apis.d.ts → commands/configuration-management/interfaces/variable-assignment-apis.constants.d.ts} +3 -1
- package/lib/commands/configuration-management/module.d.ts +15 -0
- package/lib/{services/studio → commands/configuration-management}/studio.service.d.ts +12 -5
- package/lib/commands/configuration-management/variable-command.service.d.ts +6 -0
- package/lib/{services/package-manager/variable-service.d.ts → commands/configuration-management/variable.service.d.ts} +8 -8
- package/lib/commands/cpm4/ctp-command.service.d.ts +7 -0
- package/lib/{content/manager → commands/cpm4}/ctp.analysis.manager.d.ts +2 -0
- package/lib/{content/manager → commands/cpm4}/ctp.datamodel.manager.d.ts +2 -1
- package/lib/{content/factory/ctp-manager.factory.d.ts → commands/cpm4/ctp.manager-factory.d.ts} +4 -1
- package/lib/{content/manager → commands/cpm4}/ctp.manager.d.ts +4 -2
- package/lib/commands/cpm4/module.d.ts +10 -0
- package/lib/commands/data-pipeline/connection/connection-command.service.d.ts +8 -0
- package/lib/commands/data-pipeline/connection/connection.commands.d.ts +11 -0
- package/lib/{services → commands/data-pipeline}/connection/connection.service.d.ts +4 -3
- package/lib/{api → commands/data-pipeline/data-pool}/data-pool-api.d.ts +5 -5
- package/lib/commands/data-pipeline/data-pool/data-pool-command.service.d.ts +14 -0
- package/lib/commands/data-pipeline/data-pool/data-pool-manager.factory.d.ts +9 -0
- package/lib/{services → commands/data-pipeline}/data-pool/data-pool-service.d.ts +4 -3
- package/lib/commands/data-pipeline/data-pool/data-pool.commands.d.ts +15 -0
- package/lib/{content/manager → commands/data-pipeline/data-pool}/data-pool.manager.d.ts +4 -2
- package/lib/commands/data-pipeline/module.d.ts +9 -0
- package/lib/commands/profile/module.d.ts +12 -0
- package/lib/commands/{profile.command.d.ts → profile/profile-command.service.d.ts} +1 -1
- package/lib/{api → commands/studio/api}/asset-api.d.ts +4 -4
- package/lib/{api → commands/studio/api}/compute-pool-api.d.ts +4 -4
- package/lib/{api → commands/studio/api}/node-api.d.ts +4 -4
- package/lib/{api → commands/studio/api}/package-api.d.ts +4 -4
- package/lib/{api → commands/studio/api}/package-dependencies-api.d.ts +4 -4
- package/lib/commands/studio/api/space-api.d.ts +9 -0
- package/lib/commands/studio/api/studio-variables-api.d.ts +8 -0
- package/lib/commands/studio/command-service/asset-command.service.d.ts +11 -0
- package/lib/commands/{package.command.d.ts → studio/command-service/package-command.service.d.ts} +8 -5
- package/lib/commands/studio/command-service/space-command.service.d.ts +6 -0
- package/lib/commands/studio/command-service/widget.command.d.ts +7 -0
- package/lib/{interfaces/batch-export-node-transport.d.ts → commands/studio/interfaces/batch-export-node.interfaces.d.ts} +1 -9
- package/lib/{content/factory/asset-manager.factory.d.ts → commands/studio/manager/asset.manager-factory.d.ts} +4 -1
- package/lib/{content → commands/studio}/manager/asset.manager.d.ts +4 -2
- package/lib/{content/factory/package-manager.factory.d.ts → commands/studio/manager/package.manager-factory.d.ts} +4 -1
- package/lib/{content → commands/studio}/manager/package.manager.d.ts +4 -2
- package/lib/commands/studio/manager/space.manager-factory.d.ts +8 -0
- package/lib/{content → commands/studio}/manager/space.manager.d.ts +4 -2
- package/lib/{content/factory/widget-manager.factory.d.ts → commands/studio/manager/widget.manager-factory.d.ts} +10 -7
- package/lib/{content → commands/studio}/manager/widget.manager.d.ts +4 -2
- package/lib/commands/studio/module.d.ts +21 -0
- package/lib/{services/package-manager → commands/studio/service}/asset-service.d.ts +4 -3
- package/lib/{services/package-manager/datamodel-service.d.ts → commands/studio/service/data-model.service.d.ts} +5 -5
- package/lib/{services/package-manager/package-service.d.ts → commands/studio/service/package.service.d.ts} +13 -6
- package/lib/commands/studio/service/space.service.d.ts +11 -0
- package/lib/commands/studio/service/studio-variable.service.d.ts +9 -0
- package/lib/core/command/cli-context.d.ts +17 -0
- package/lib/core/command/module-handler.d.ts +57 -0
- package/lib/core/http/base-api.d.ts +32 -0
- package/lib/{services/http-client-service.v2.d.ts → core/http/http-client.d.ts} +8 -3
- package/lib/{content/manager → core/http/http-shared}/base.manager.d.ts +4 -6
- package/lib/core/http/http-shared/base.manager.helper.d.ts +4 -0
- package/lib/{services → core/profile}/profile.service.d.ts +2 -1
- package/lib/{validators → core/profile}/profile.validator.d.ts +1 -1
- package/lib/{services → core/utils}/file-service.d.ts +0 -2
- package/lib/core/utils/question.service.d.ts +10 -0
- package/package.json +3 -3
- package/api/batch-import-export-api.js +0 -51
- package/api/variables-api.js +0 -56
- package/commands/config.command.js +0 -57
- package/commands/profile.command.js +0 -88
- package/commands/widget.command.js +0 -36
- package/content-cli-analyze.js +0 -56
- package/content-cli-config.js +0 -117
- package/content-cli-export.js +0 -90
- package/content-cli-get.js +0 -52
- package/content-cli-import.js +0 -93
- package/content-cli-list.js +0 -129
- package/content-cli-profile.js +0 -64
- package/content-cli-pull.js +0 -104
- package/content-cli-push.js +0 -196
- package/content-cli-set.js +0 -55
- package/content-cli-update.js +0 -44
- package/interfaces/variable-assignment-api.interface.js +0 -12
- package/lib/api/space-api.d.ts +0 -9
- package/lib/api/variables-api.d.ts +0 -14
- package/lib/commands/analysis-bookmarks.command.d.ts +0 -6
- package/lib/commands/asset.command.d.ts +0 -8
- package/lib/commands/connection.command.d.ts +0 -5
- package/lib/commands/ctp.command.d.ts +0 -6
- package/lib/commands/data-pool.command.d.ts +0 -11
- package/lib/commands/space.command.d.ts +0 -5
- package/lib/commands/variable.command.d.ts +0 -3
- package/lib/commands/widget.command.d.ts +0 -5
- package/lib/content/factory/analysis-bookmarks-manager.factory.d.ts +0 -5
- package/lib/content/factory/data-pool-manager.factory.d.ts +0 -6
- package/lib/content/factory/skill-manager.factory.d.ts +0 -5
- package/lib/content/factory/space-manager.factory.d.ts +0 -5
- package/lib/content-cli-analyze.d.ts +0 -1
- package/lib/content-cli-config.d.ts +0 -8
- package/lib/content-cli-export.d.ts +0 -6
- package/lib/content-cli-get.d.ts +0 -1
- package/lib/content-cli-import.d.ts +0 -6
- package/lib/content-cli-list.d.ts +0 -9
- package/lib/content-cli-profile.d.ts +0 -1
- package/lib/content-cli-pull.d.ts +0 -1
- package/lib/content-cli-push.d.ts +0 -1
- package/lib/content-cli-set.d.ts +0 -1
- package/lib/content-cli-update.d.ts +0 -1
- package/lib/interfaces/variable-assignment-api.interface.d.ts +0 -3
- package/lib/services/command.service.d.ts +0 -6
- package/lib/services/content.service.d.ts +0 -11
- package/lib/services/context.service.d.ts +0 -13
- package/lib/services/http-client.service.d.ts +0 -15
- package/lib/services/package-manager/space-service.d.ts +0 -11
- package/lib/services/question.service.d.ts +0 -4
- package/lib/util/context-initializer.d.ts +0 -3
- package/lib/util/program.d.ts +0 -2
- package/services/command.service.js +0 -24
- package/services/content.service.js +0 -130
- package/services/http-client.service.js +0 -157
- package/util/context-initializer.js +0 -39
- package/util/logger.js +0 -49
- package/util/program.js +0 -16
- /package/{interfaces/batch-export-import-constants.js → commands/configuration-management/interfaces/batch-export-import.constants.js} +0 -0
- /package/{interfaces/diff-package.transport.js → commands/configuration-management/interfaces/diff-package.interfaces.js} +0 -0
- /package/{interfaces/batch-export-node-transport.js → commands/configuration-management/interfaces/package-export.interfaces.js} +0 -0
- /package/{api/variable-assignment-apis.js → commands/configuration-management/interfaces/variable-assignment-apis.constants.js} +0 -0
- /package/{interfaces → commands/data-pipeline/data-pool}/data-pool-manager.interfaces.js +0 -0
- /package/{interfaces/manager-config.interface.js → commands/studio/interfaces/batch-export-node.interfaces.js} +0 -0
- /package/{interfaces/manifest-transport.js → commands/studio/interfaces/manifest.interface.js} +0 -0
- /package/{interfaces → commands/studio/interfaces}/package-manager.interfaces.js +0 -0
- /package/{interfaces → commands/studio/interfaces}/save-content-node.interface.js +0 -0
- /package/{interfaces/package-export-transport.js → commands/studio/interfaces/space.interface.js} +0 -0
- /package/{util → commands/studio/utils}/semantic-versioning.js +0 -0
- /package/{util → core/http}/axios-initializer.js +0 -0
- /package/{interfaces/save-space.interface.js → core/http/http-shared/manager-config.interface.js} +0 -0
- /package/{util → core/http}/tracing.js +0 -0
- /package/{interfaces → core/profile}/profile.interface.js +0 -0
- /package/{util → core/utils}/json.js +0 -0
- /package/{util → core/utils}/yaml.js +0 -0
- /package/lib/{interfaces/batch-export-import-constants.d.ts → commands/configuration-management/interfaces/batch-export-import.constants.d.ts} +0 -0
- /package/lib/{interfaces/diff-package.transport.d.ts → commands/configuration-management/interfaces/diff-package.interfaces.d.ts} +0 -0
- /package/lib/{interfaces → commands/data-pipeline/data-pool}/data-pool-manager.interfaces.d.ts +0 -0
- /package/lib/{interfaces/manifest-transport.d.ts → commands/studio/interfaces/manifest.interface.d.ts} +0 -0
- /package/lib/{interfaces → commands/studio/interfaces}/package-manager.interfaces.d.ts +0 -0
- /package/lib/{interfaces → commands/studio/interfaces}/save-content-node.interface.d.ts +0 -0
- /package/lib/{interfaces/save-space.interface.d.ts → commands/studio/interfaces/space.interface.d.ts} +0 -0
- /package/lib/{util → commands/studio/utils}/semantic-versioning.d.ts +0 -0
- /package/lib/{util → core/http}/axios-initializer.d.ts +0 -0
- /package/lib/{interfaces → core/http/http-shared}/manager-config.interface.d.ts +0 -0
- /package/lib/{util → core/http}/tracing.d.ts +0 -0
- /package/lib/{interfaces → core/profile}/profile.interface.d.ts +0 -0
- /package/lib/{util → core/utils}/json.d.ts +0 -0
- /package/lib/{util → core/utils}/logger.d.ts +0 -0
- /package/lib/{util → core/utils}/version.d.ts +0 -0
- /package/lib/{util → core/utils}/yaml.d.ts +0 -0
|
@@ -13,7 +13,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
13
13
|
if (v !== undefined) module.exports = v;
|
|
14
14
|
}
|
|
15
15
|
else if (typeof define === "function" && define.amd) {
|
|
16
|
-
define(["require", "exports", "fs", "path", "
|
|
16
|
+
define(["require", "exports", "fs", "path", "./logger"], factory);
|
|
17
17
|
}
|
|
18
18
|
})(function (require, exports) {
|
|
19
19
|
"use strict";
|
|
@@ -21,8 +21,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
exports.fileService = exports.FileService = void 0;
|
|
22
22
|
const fs = require("fs");
|
|
23
23
|
const path = require("path");
|
|
24
|
-
const logger_1 = require("
|
|
25
|
-
const yaml_1 = require("../util/yaml");
|
|
24
|
+
const logger_1 = require("./logger");
|
|
26
25
|
class FileService {
|
|
27
26
|
writeToFileWithGivenName(data, filename) {
|
|
28
27
|
fs.writeFileSync(path.resolve(process.cwd(), filename), this.getSerializedFileContent(data), {
|
|
@@ -32,10 +31,6 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
32
31
|
createDirectoryWithGivenName(dirName) {
|
|
33
32
|
fs.mkdirSync(path.resolve(process.cwd(), dirName));
|
|
34
33
|
}
|
|
35
|
-
readManifestFile(importedFileName) {
|
|
36
|
-
const manifest = (0, yaml_1.parse)(fs.readFileSync(path.resolve(importedFileName + "/manifest.yml"), { encoding: "utf-8" }));
|
|
37
|
-
return Promise.all(manifest);
|
|
38
|
-
}
|
|
39
34
|
readFileToJson(fileName) {
|
|
40
35
|
return __awaiter(this, void 0, void 0, function* () {
|
|
41
36
|
const fileContent = this.readFile(fileName);
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
+
var v = factory(require, exports);
|
|
4
|
+
if (v !== undefined) module.exports = v;
|
|
5
|
+
}
|
|
6
|
+
else if (typeof define === "function" && define.amd) {
|
|
7
|
+
define(["require", "exports", "winston", "winston-transport", "os", "path", "fs"], factory);
|
|
8
|
+
}
|
|
9
|
+
})(function (require, exports) {
|
|
10
|
+
"use strict";
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.GracefulError = exports.FatalError = exports.logger = void 0;
|
|
13
|
+
const winston = require("winston");
|
|
14
|
+
const Transport = require("winston-transport");
|
|
15
|
+
const os = require("os");
|
|
16
|
+
const path = require("path");
|
|
17
|
+
const fs = require("fs");
|
|
18
|
+
class CustomTransport extends Transport {
|
|
19
|
+
constructor(opts) {
|
|
20
|
+
super(opts);
|
|
21
|
+
}
|
|
22
|
+
log(info, cb) {
|
|
23
|
+
setImmediate(() => {
|
|
24
|
+
this.emit("logged", info);
|
|
25
|
+
});
|
|
26
|
+
cb();
|
|
27
|
+
if (info.error || (info.errno && info.errno !== "__CELGRACEFULERROR")) {
|
|
28
|
+
process.exit(1);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
// log into the same directory as where the profiles are, to avoid creating more
|
|
33
|
+
// directories for now. Consider changing this to a general 'home' directory such
|
|
34
|
+
// as .celonis-cli or alike.
|
|
35
|
+
const logDirName = ".celonis-content-cli-profiles";
|
|
36
|
+
const logFileName = "celonis-cli.log";
|
|
37
|
+
const exceptionLogFileName = "exceptions.log";
|
|
38
|
+
const maxLogSizeMB = 3;
|
|
39
|
+
const logDir = path.join(os.homedir(), logDirName);
|
|
40
|
+
const logFilePath = path.join(logDir, logFileName);
|
|
41
|
+
const exceptionLogFilePath = path.join(logDir, exceptionLogFileName);
|
|
42
|
+
const maxSizeBytes = maxLogSizeMB * 1024 * 1024; // 3 MB in bytes
|
|
43
|
+
// --- Ensure log directory exists ---
|
|
44
|
+
try {
|
|
45
|
+
if (!fs.existsSync(logDir)) {
|
|
46
|
+
fs.mkdirSync(logDir, { recursive: true });
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
catch (error) {
|
|
50
|
+
console.error(`Error creating log directory: ${logDir}`, error);
|
|
51
|
+
}
|
|
52
|
+
exports.logger = winston.createLogger({
|
|
53
|
+
format: winston.format.combine(winston.format.cli()),
|
|
54
|
+
level: "debug",
|
|
55
|
+
transports: [
|
|
56
|
+
new winston.transports.Console({
|
|
57
|
+
level: "info",
|
|
58
|
+
format: winston.format.combine(winston.format.colorize()),
|
|
59
|
+
}),
|
|
60
|
+
new winston.transports.File({
|
|
61
|
+
level: "info", // Log everything from debug up to the file
|
|
62
|
+
filename: logFilePath,
|
|
63
|
+
format: winston.format.combine(winston.format.timestamp(), // Add timestamp to file logs
|
|
64
|
+
winston.format.errors({ stack: true }), // Log stack traces
|
|
65
|
+
winston.format.json() // Log in JSON format
|
|
66
|
+
),
|
|
67
|
+
maxsize: maxSizeBytes,
|
|
68
|
+
maxFiles: 5,
|
|
69
|
+
tailable: true,
|
|
70
|
+
}),
|
|
71
|
+
new CustomTransport({})
|
|
72
|
+
],
|
|
73
|
+
exceptionHandlers: [
|
|
74
|
+
new winston.transports.Console({
|
|
75
|
+
format: winston.format.combine(winston.format.colorize()),
|
|
76
|
+
}),
|
|
77
|
+
new winston.transports.File({
|
|
78
|
+
filename: exceptionLogFilePath, // Separate file recommended
|
|
79
|
+
format: winston.format.combine(winston.format.timestamp(), winston.format.errors({ stack: true }), winston.format.json()),
|
|
80
|
+
maxsize: maxSizeBytes,
|
|
81
|
+
maxFiles: 2, // Keep fewer exception logs if desired
|
|
82
|
+
tailable: true,
|
|
83
|
+
}),
|
|
84
|
+
new CustomTransport({})
|
|
85
|
+
],
|
|
86
|
+
exitOnError: false,
|
|
87
|
+
});
|
|
88
|
+
// tslint:disable-next-line: max-classes-per-file
|
|
89
|
+
class FatalError extends Error {
|
|
90
|
+
constructor() {
|
|
91
|
+
super(...arguments);
|
|
92
|
+
this.error = "FatalError";
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
exports.FatalError = FatalError;
|
|
96
|
+
// By default, the logger will process.exit(1) when logging an uncaught fatal error
|
|
97
|
+
// This interface allows us to throw errors that do not force the process to exit and can be handled gracefully
|
|
98
|
+
// tslint:disable-next-line: max-classes-per-file
|
|
99
|
+
class GracefulError extends Error {
|
|
100
|
+
}
|
|
101
|
+
exports.GracefulError = GracefulError;
|
|
102
|
+
});
|
|
@@ -20,19 +20,30 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
20
20
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
21
|
exports.QuestionService = void 0;
|
|
22
22
|
const readline = require("readline");
|
|
23
|
+
/**
|
|
24
|
+
* Simple method to get input from the user/console using ReadLine. The
|
|
25
|
+
* class must be closed in order to avoid the CLI to not terminate properly.
|
|
26
|
+
*/
|
|
23
27
|
class QuestionService {
|
|
24
|
-
|
|
28
|
+
constructor() {
|
|
29
|
+
this.readLine = readline.createInterface({
|
|
30
|
+
input: process.stdin,
|
|
31
|
+
output: process.stdout,
|
|
32
|
+
terminal: true,
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
ask(question) {
|
|
25
36
|
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
return new Promise(
|
|
37
|
+
return new Promise(resolve => {
|
|
27
38
|
this.readLine.question(question, input => resolve(input));
|
|
28
39
|
});
|
|
29
40
|
});
|
|
30
41
|
}
|
|
42
|
+
close() {
|
|
43
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
44
|
+
this.readLine.close();
|
|
45
|
+
});
|
|
46
|
+
}
|
|
31
47
|
}
|
|
32
48
|
exports.QuestionService = QuestionService;
|
|
33
|
-
QuestionService.readLine = readline.createInterface({
|
|
34
|
-
input: process.stdin,
|
|
35
|
-
output: process.stdout,
|
|
36
|
-
terminal: true,
|
|
37
|
-
});
|
|
38
49
|
});
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.VersionUtils = void 0;
|
|
13
13
|
// tslint:disable-next-line:no-var-requires
|
|
14
|
-
const { version } = require("
|
|
14
|
+
const { version } = require("../../../package.json");
|
|
15
15
|
class VersionUtils {
|
|
16
16
|
static getCurrentCliVersion() {
|
|
17
17
|
return version;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
import * as FormData from "form-data";
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
import { Context } from "../../../core/command/cli-context";
|
|
4
|
+
export declare class ActionFlowApi {
|
|
5
|
+
private httpClient;
|
|
6
|
+
constructor(context: Context);
|
|
5
7
|
exportRawAssets(packageId: string): Promise<Buffer>;
|
|
6
8
|
analyzeAssets(packageId: string): Promise<any>;
|
|
7
9
|
importAssets(packageId: string, data: FormData, dryRun: boolean): Promise<any>;
|
|
8
10
|
}
|
|
9
|
-
export declare const actionFlowApi: ActionFlowApi;
|
|
10
|
-
export {};
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
export declare class ActionFlowCommandService {
|
|
3
|
+
private actionFlowService;
|
|
4
|
+
constructor(context: Context);
|
|
2
5
|
exportActionFlows(packageId: string, metadataFile: string): Promise<void>;
|
|
3
6
|
analyzeActionFlows(packageId: string, outputToJsonFile: boolean): Promise<void>;
|
|
4
7
|
importActionFlows(packageId: string, filePath: string, dryRun: boolean, outputToJsonFile: boolean): Promise<void>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
export declare class ActionFlowService {
|
|
2
3
|
static readonly METADATA_FILE_NAME = "metadata.json";
|
|
4
|
+
private actionFlowApi;
|
|
5
|
+
constructor(context: Context);
|
|
3
6
|
exportActionFlows(packageId: string, metadataFilePath: string): Promise<void>;
|
|
4
7
|
analyzeActionFlows(packageId: string, outputToJsonFile: boolean): Promise<void>;
|
|
5
8
|
importActionFlows(packageId: string, filePath: string, dryRun: boolean, outputToJsonFile: boolean): Promise<void>;
|
|
6
9
|
private createBodyForImport;
|
|
7
10
|
private attachMetadataFile;
|
|
8
11
|
}
|
|
9
|
-
export declare const actionFlowService: ActionFlowService;
|
|
10
|
-
export declare const metadataFileName = "metadata.json";
|
|
11
|
-
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Commands related to the Action Flows area.
|
|
3
|
+
*/
|
|
4
|
+
import { Configurator, IModule } from "../../core/command/module-handler";
|
|
5
|
+
import { Context } from "../../core/command/cli-context";
|
|
6
|
+
declare class Module extends IModule {
|
|
7
|
+
register(context: Context, configurator: Configurator): void;
|
|
8
|
+
private analyzeActionFlows;
|
|
9
|
+
private exportActionFlows;
|
|
10
|
+
private importActionFlows;
|
|
11
|
+
private pullSkill;
|
|
12
|
+
private pushSkill;
|
|
13
|
+
}
|
|
14
|
+
export = Module;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
export declare class SkillCommandService {
|
|
3
3
|
private skillManagerFactory;
|
|
4
|
+
constructor(context: Context);
|
|
4
5
|
pullSkill(profile: string, projectId: string, skillId: string): Promise<void>;
|
|
5
6
|
pushSkill(profile: string, projectId: string, filename: string): Promise<void>;
|
|
6
7
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
import { SkillManager } from "./skill.manager";
|
|
3
|
+
export declare class SkillManagerFactory {
|
|
4
|
+
private readonly context;
|
|
5
|
+
constructor(context: Context);
|
|
6
|
+
createManager(projectId: string, skillId: string, filename: string): SkillManager;
|
|
7
|
+
private readFile;
|
|
8
|
+
}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
import { BaseManager } from "../../../core/http/http-shared/base.manager";
|
|
3
|
+
import { ManagerConfig } from "../../../core/http/http-shared/manager-config.interface";
|
|
3
4
|
export declare class SkillManager extends BaseManager {
|
|
4
5
|
private static BASE_URL;
|
|
5
6
|
private _skillId;
|
|
6
7
|
private _projectId;
|
|
7
8
|
private _content;
|
|
9
|
+
constructor(context: Context);
|
|
8
10
|
get content(): any;
|
|
9
11
|
set content(value: any);
|
|
10
12
|
get skillId(): string;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class AnalysisBookmarksCommandService {
|
|
3
|
+
private analysisBookmarksManagerFactory;
|
|
4
|
+
constructor(context: Context);
|
|
5
|
+
pullAnalysisBookmarks(analysisId: string, type: string): Promise<void>;
|
|
6
|
+
pushAnalysisBookmarks(analysisId: string, filename: string): Promise<void>;
|
|
7
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AnalysisBookmarksManager } from "./analysis-bookmarks.manager";
|
|
2
|
+
import { Context } from "../../core/command/cli-context";
|
|
3
|
+
export declare class AnalysisBookmarksManagerFactory {
|
|
4
|
+
private readonly context;
|
|
5
|
+
constructor(context: Context);
|
|
6
|
+
createAnalysisBookmarksManager(filename: string, analysisId: string, type?: string): AnalysisBookmarksManager;
|
|
7
|
+
private readFile;
|
|
8
|
+
}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
import { BaseManager } from "../../core/http/http-shared/base.manager";
|
|
3
|
+
import { ManagerConfig } from "../../core/http/http-shared/manager-config.interface";
|
|
3
4
|
export declare class AnalysisBookmarksManager extends BaseManager {
|
|
4
5
|
private static BASE_URL;
|
|
5
6
|
private static ANALYSIS_BOOKMARKS_FILE_PREFIX;
|
|
6
7
|
private _analysisId;
|
|
7
8
|
private _fileName;
|
|
8
9
|
private _type;
|
|
10
|
+
constructor(context: Context);
|
|
9
11
|
get fileName(): string;
|
|
10
12
|
set fileName(value: string);
|
|
11
13
|
get analysisId(): string;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Commands related to the Analysis feature.
|
|
3
|
+
*/
|
|
4
|
+
import { Configurator, IModule } from "../../core/command/module-handler";
|
|
5
|
+
import { Context } from "../../core/command/cli-context";
|
|
6
|
+
declare class Module extends IModule {
|
|
7
|
+
register(context: Context, configurator: Configurator): void;
|
|
8
|
+
private pullAnalysisBookmarks;
|
|
9
|
+
private pushAnalysisBookmarks;
|
|
10
|
+
}
|
|
11
|
+
export = Module;
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { PackageExportTransport, PackageKeyAndVersionPair, PostPackageImportData, VariableManifestTransport } from "../interfaces/package-export-transport";
|
|
3
2
|
import * as FormData from "form-data";
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
import { PackageExportTransport, PackageKeyAndVersionPair, PostPackageImportData, VariableManifestTransport } from "../interfaces/package-export.interfaces";
|
|
4
|
+
import { Context } from "../../../core/command/cli-context";
|
|
5
|
+
export declare class BatchImportExportApi {
|
|
6
|
+
private httpClient;
|
|
7
|
+
constructor(context: Context);
|
|
6
8
|
findAllActivePackages(flavors: string[], withDependencies?: boolean): Promise<PackageExportTransport[]>;
|
|
9
|
+
findActivePackagesByVariableValue(flavors: string[], variableValue: string, variableType: string): Promise<PackageExportTransport[]>;
|
|
7
10
|
findActivePackagesByKeys(packageKeys: string[], withDependencies?: boolean): Promise<PackageExportTransport[]>;
|
|
8
11
|
exportPackages(packageKeys: string[], withDependencies?: boolean): Promise<Buffer>;
|
|
9
12
|
importPackages(data: FormData, overwrite: boolean): Promise<PostPackageImportData[]>;
|
|
10
13
|
findVariablesWithValuesByPackageKeysAndVersion(packagesByKeyAndVersion: PackageKeyAndVersionPair[]): Promise<VariableManifestTransport[]>;
|
|
11
14
|
}
|
|
12
|
-
export declare const batchImportExportApi: BatchImportExportApi;
|
|
13
|
-
export {};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { PackageDiffMetadata, PackageDiffTransport } from "../interfaces/diff-package.transport";
|
|
2
1
|
import * as FormData from "form-data";
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
import { Context } from "../../../core/command/cli-context";
|
|
3
|
+
import { PackageDiffMetadata, PackageDiffTransport } from "../interfaces/diff-package.interfaces";
|
|
4
|
+
export declare class DiffApi {
|
|
5
|
+
private httpClient;
|
|
6
|
+
constructor(context: Context);
|
|
5
7
|
diffPackages(data: FormData): Promise<PackageDiffTransport[]>;
|
|
6
8
|
hasChanges(data: FormData): Promise<PackageDiffMetadata[]>;
|
|
7
9
|
}
|
|
8
|
-
export declare const diffApi: DiffApi;
|
|
9
|
-
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import { URLSearchParams } from "url";
|
|
3
|
+
import { Context } from "../../../core/command/cli-context";
|
|
4
|
+
export declare class VariableAssignmentCandidatesApi {
|
|
5
|
+
private httpClient;
|
|
6
|
+
constructor(context: Context);
|
|
7
|
+
getCandidateAssignments(type: string, params: URLSearchParams): Promise<object[]>;
|
|
8
|
+
}
|
|
@@ -1,8 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class BatchImportExportService {
|
|
3
|
+
private batchImportExportApi;
|
|
4
|
+
private studioPackageApi;
|
|
5
|
+
private studioService;
|
|
6
|
+
constructor(context: Context);
|
|
2
7
|
listActivePackages(flavors: string[]): Promise<void>;
|
|
3
8
|
findAndExportListOfActivePackages(flavors: string[], packageKeys: string[], withDependencies: boolean): Promise<void>;
|
|
4
9
|
batchExportPackages(packageKeys: string[], withDependencies?: boolean): Promise<void>;
|
|
5
10
|
batchImportPackages(file: string, overwrite: boolean): Promise<void>;
|
|
11
|
+
findAndExportListOfActivePackagesByVariableValue(flavors: string[], variableValue: string, variableType: string): Promise<void>;
|
|
12
|
+
listActivePackagesByVariableValue(flavors: string[], variableValue: string, variableType: string): Promise<void>;
|
|
6
13
|
private exportListOfPackages;
|
|
7
14
|
private getVersionsByPackageKey;
|
|
8
15
|
private getVersionedVariablesForPackagesWithKeys;
|
|
@@ -10,5 +17,3 @@ declare class BatchImportExportService {
|
|
|
10
17
|
private getReadableStream;
|
|
11
18
|
private parseEntryData;
|
|
12
19
|
}
|
|
13
|
-
export declare const batchImportExportService: BatchImportExportService;
|
|
14
|
-
export {};
|
package/lib/commands/{config.command.d.ts → configuration-management/config-command.service.d.ts}
RENAMED
|
@@ -1,7 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class ConfigCommandService {
|
|
3
|
+
private batchImportExportService;
|
|
4
|
+
private variableService;
|
|
5
|
+
private diffService;
|
|
6
|
+
constructor(context: Context);
|
|
7
|
+
listActivePackages(jsonResponse: boolean, flavors: string[], withDependencies: boolean, packageKeys: string[], variableValue: string, variableType: string): Promise<void>;
|
|
3
8
|
listVariables(jsonResponse: boolean, keysByVersion: string[], keysByVersionFile: string): Promise<void>;
|
|
4
9
|
batchExportPackages(packageKeys: string[], withDependencies?: boolean): Promise<void>;
|
|
5
10
|
batchImportPackages(file: string, overwrite: boolean): Promise<void>;
|
|
6
11
|
diffPackages(file: string, hasChanges: boolean, jsonResponse: boolean): Promise<void>;
|
|
12
|
+
private listPackagesByVariableValue;
|
|
7
13
|
}
|
|
@@ -1,4 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class DiffService {
|
|
3
|
+
private diffApi;
|
|
4
|
+
constructor(context: Context);
|
|
2
5
|
diffPackages(file: string, hasChanges: boolean, jsonResponse: boolean): Promise<void>;
|
|
3
6
|
private hasChanges;
|
|
4
7
|
private diffPackagesAndReturnDiff;
|
|
@@ -9,5 +12,3 @@ declare class DiffService {
|
|
|
9
12
|
private buildStringResponseForPackageDiffs;
|
|
10
13
|
private buildStringResponseForPackageDiffMetadataList;
|
|
11
14
|
}
|
|
12
|
-
export declare const diffService: DiffService;
|
|
13
|
-
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
-
import { StudioComputeNodeDescriptor, VariableDefinition, VariablesAssignments } from "
|
|
3
|
-
import { SpaceTransport } from "
|
|
2
|
+
import { StudioComputeNodeDescriptor, VariableDefinition, VariablesAssignments } from "../../studio/interfaces/package-manager.interfaces";
|
|
3
|
+
import { SpaceTransport } from "../../studio/interfaces/space.interface";
|
|
4
4
|
export interface DependencyTransport {
|
|
5
5
|
key: string;
|
|
6
6
|
version: string;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Commands related to Celonis configuration management.
|
|
3
|
+
*/
|
|
4
|
+
import { Configurator, IModule } from "../../core/command/module-handler";
|
|
5
|
+
import { Context } from "../../core/command/cli-context";
|
|
6
|
+
declare class Module extends IModule {
|
|
7
|
+
register(context: Context, configurator: Configurator): void;
|
|
8
|
+
private listActivePackages;
|
|
9
|
+
private batchExportPackages;
|
|
10
|
+
private batchImportPackages;
|
|
11
|
+
private diffPackages;
|
|
12
|
+
private listVariables;
|
|
13
|
+
private listAssignments;
|
|
14
|
+
}
|
|
15
|
+
export = Module;
|
|
@@ -1,8 +1,17 @@
|
|
|
1
|
-
import { PackageExportTransport, StudioPackageManifest, VariableManifestTransport } from "../../interfaces/package-export-transport";
|
|
2
|
-
import { ContentNodeTransport } from "../../interfaces/package-manager.interfaces";
|
|
3
1
|
import { IZipEntry } from "adm-zip";
|
|
4
2
|
import * as AdmZip from "adm-zip";
|
|
5
|
-
|
|
3
|
+
import { PackageExportTransport, StudioPackageManifest, VariableManifestTransport } from "./interfaces/package-export.interfaces";
|
|
4
|
+
import { ContentNodeTransport } from "../studio/interfaces/package-manager.interfaces";
|
|
5
|
+
import { Context } from "../../core/command/cli-context";
|
|
6
|
+
export declare class StudioService {
|
|
7
|
+
private studioPackageApi;
|
|
8
|
+
private studioNodeApi;
|
|
9
|
+
private studioSpaceApi;
|
|
10
|
+
private studioVariablesApi;
|
|
11
|
+
private studioDataModelService;
|
|
12
|
+
private studioSpaceService;
|
|
13
|
+
private studioVariableService;
|
|
14
|
+
constructor(context: Context);
|
|
6
15
|
getExportPackagesWithStudioData(packagesToExport: PackageExportTransport[], withDependencies: boolean): Promise<PackageExportTransport[]>;
|
|
7
16
|
fixConnectionVariables(variables: VariableManifestTransport[]): VariableManifestTransport[];
|
|
8
17
|
getStudioPackageManifests(studioPackageKeys: string[]): Promise<StudioPackageManifest[]>;
|
|
@@ -21,5 +30,3 @@ declare class StudioService {
|
|
|
21
30
|
private assignRuntimeVariables;
|
|
22
31
|
private updateSpaceIdForNode;
|
|
23
32
|
}
|
|
24
|
-
export declare const studioService: StudioService;
|
|
25
|
-
export {};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
declare class VariableService {
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class VariableService {
|
|
3
|
+
private batchImportExportApi;
|
|
4
|
+
private variableAssignmentCandidatesApi;
|
|
5
|
+
private studioService;
|
|
6
|
+
constructor(context: Context);
|
|
7
|
+
listVariables(keysByVersion: string[], keysByVersionFile: string): Promise<void>;
|
|
5
8
|
listCandidateAssignments(type: string, params: string): Promise<void>;
|
|
6
9
|
findAndExportCandidateAssignments(type: string, params: string): Promise<void>;
|
|
7
|
-
listVariables(keysByVersion: string[], keysByVersionFile: string): Promise<void>;
|
|
8
10
|
exportVariables(keysByVersion: string[], keysByVersionFile: string): Promise<void>;
|
|
9
|
-
private parseParams;
|
|
10
11
|
private getVersionedVariablesByKeyVersionPairs;
|
|
11
12
|
private buildKeyVersionPairs;
|
|
12
13
|
private buildKeyAndVersionPairsFromArrayInput;
|
|
13
14
|
private exportToJson;
|
|
15
|
+
private parseParams;
|
|
14
16
|
}
|
|
15
|
-
export declare const variableService: VariableService;
|
|
16
|
-
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
export declare class CTPCommandService {
|
|
3
|
+
private ctpManagerFactory;
|
|
4
|
+
constructor(context: Context);
|
|
5
|
+
pushCTPFile(filename: string, password: string, pushAnalysis: boolean, pushDataModels: boolean, existingPoolId: string, globalPoolName: string, spaceKey: string): Promise<void>;
|
|
6
|
+
private validateParamsForDataModelPush;
|
|
7
|
+
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { CtpManager } from "./ctp.manager";
|
|
2
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
3
|
export declare class CtpAnalysisManager extends CtpManager {
|
|
3
4
|
private static BASE_URL;
|
|
5
|
+
constructor(context: Context);
|
|
4
6
|
protected getUrl(): string;
|
|
5
7
|
getBody(): any;
|
|
6
8
|
}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { CtpManager } from "./ctp.manager";
|
|
2
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
3
|
export declare class CtpDataModelManager extends CtpManager {
|
|
3
4
|
private static BASE_URL;
|
|
4
5
|
private readonly existingPoolId;
|
|
5
6
|
private readonly globalPoolName;
|
|
6
|
-
constructor(existingPoolId: string, globalPoolName: string);
|
|
7
|
+
constructor(context: Context, existingPoolId: string, globalPoolName: string);
|
|
7
8
|
protected getUrl(): string;
|
|
8
9
|
protected getBody(): object;
|
|
9
10
|
}
|
package/lib/{content/factory/ctp-manager.factory.d.ts → commands/cpm4/ctp.manager-factory.d.ts}
RENAMED
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
import { CtpManager } from "./ctp.manager";
|
|
2
3
|
export declare class CTPManagerFactory {
|
|
4
|
+
private readonly context;
|
|
5
|
+
constructor(context: Context);
|
|
3
6
|
createCtpAnalysisManager(filename: string, password: string, spaceKey: string): CtpManager;
|
|
4
7
|
createCtpDataModelManager(filename: string, password: string, existingPoolId: string, globalPoolName: string): CtpManager;
|
|
5
8
|
private initManager;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Context } from "../../core/command/cli-context";
|
|
2
|
+
import { BaseManager } from "../../core/http/http-shared/base.manager";
|
|
3
|
+
import { ManagerConfig } from "../../core/http/http-shared/manager-config.interface";
|
|
3
4
|
export declare abstract class CtpManager extends BaseManager {
|
|
4
5
|
protected _content: any;
|
|
5
6
|
protected _password: string;
|
|
6
7
|
protected _spaceKey?: string;
|
|
8
|
+
protected constructor(context: Context);
|
|
7
9
|
get content(): any;
|
|
8
10
|
set content(value: any);
|
|
9
11
|
get password(): string;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Commands related to the CPM4 area.
|
|
3
|
+
*/
|
|
4
|
+
import { Configurator, IModule } from "../../core/command/module-handler";
|
|
5
|
+
import { Context } from "../../core/command/cli-context";
|
|
6
|
+
declare class Module extends IModule {
|
|
7
|
+
register(context: Context, configurator: Configurator): void;
|
|
8
|
+
private pushCTPFile;
|
|
9
|
+
}
|
|
10
|
+
export = Module;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
export declare class ConnectionCommandService {
|
|
3
|
+
private connectionService;
|
|
4
|
+
constructor(context: Context);
|
|
5
|
+
updateProperty(dataPoolId: string, connectionId: string, property: string, value: string): Promise<void>;
|
|
6
|
+
getProperties(dataPoolId: string, connectionId: string): Promise<void>;
|
|
7
|
+
listConnections(dataPoolId: string): Promise<any>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Commands related to the Data Pool Connections.
|
|
3
|
+
*/
|
|
4
|
+
import { Configurator } from "../../../core/command/module-handler";
|
|
5
|
+
import { Context } from "../../../core/command/cli-context";
|
|
6
|
+
export declare class ConnectionCommands {
|
|
7
|
+
register(context: Context, configurator: Configurator): void;
|
|
8
|
+
private getCommandProperties;
|
|
9
|
+
private listConnections;
|
|
10
|
+
private updateConnectionProperty;
|
|
11
|
+
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import { Context } from "../../../core/command/cli-context";
|
|
2
|
+
export declare class ConnectionService {
|
|
3
|
+
private dataPoolApi;
|
|
4
|
+
constructor(context: Context);
|
|
2
5
|
findAllConnections(dataPoolId: string): Promise<any[]>;
|
|
3
6
|
listProperties(dataPoolId: string, connectionId: string): Promise<any[]>;
|
|
4
7
|
updateProperty(dataPoolId: string, connectionId: string, property: string, value: string): Promise<void>;
|
|
5
8
|
}
|
|
6
|
-
export declare const connectionService: ConnectionService;
|
|
7
|
-
export {};
|