deepline 0.3.482 → 0.3.483
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/dist/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/cli/{auth-R5GFDAMI.mjs → auth-2NXF6Q3Q.mjs} +5 -5
- package/dist/cli/auth-JHQKM6QY.js +43 -0
- package/dist/cli/{billing-DXKVQPTC.js → billing-5PW4L5WD.js} +79 -79
- package/dist/cli/{billing-SO5SFQFC.mjs → billing-W2Y4EOZP.mjs} +6 -6
- package/dist/cli/{chunk-DYHBKFCW.mjs → chunk-25IGCYJP.mjs} +3 -3
- package/dist/cli/{chunk-3EN2BLAS.js → chunk-2JWG2H2N.js} +1 -1
- package/dist/cli/{chunk-Y4Y2QUFL.js → chunk-2MKX3HV3.js} +5 -5
- package/dist/cli/{chunk-LKFQERA6.js → chunk-2T4OSJEH.js} +21 -21
- package/dist/cli/{chunk-JLI7SK55.mjs → chunk-4X23YY2E.mjs} +5 -5
- package/dist/cli/chunk-5AEDYVB6.mjs +6 -0
- package/dist/cli/{chunk-SFZCKYTD.js → chunk-5ICAG4RE.js} +9 -9
- package/dist/cli/{chunk-UVU4OCYO.js → chunk-5JCXS4MP.js} +5 -5
- package/dist/cli/{chunk-OVSSKTXG.js → chunk-5LHU7NUS.js} +3 -3
- package/dist/cli/{chunk-DZRHML3J.js → chunk-62XGOB2D.js} +26 -26
- package/dist/cli/{chunk-NXTZ4UNI.js → chunk-75IIHFN6.js} +4 -4
- package/dist/cli/{chunk-LVOEZVDW.mjs → chunk-7APXZ3CX.mjs} +2 -2
- package/dist/cli/{chunk-M6B2OZGA.js → chunk-7TKLISLM.js} +3 -3
- package/dist/cli/{chunk-RCWBWM5J.mjs → chunk-AWAFYRFV.mjs} +1 -1
- package/dist/cli/{chunk-RLYJ4O6Q.js → chunk-B7HQL77V.js} +53 -53
- package/dist/cli/{chunk-RLG2MNXH.mjs → chunk-C3LJSOQ6.mjs} +4 -4
- package/dist/cli/chunk-D3BCSAN7.js +6 -0
- package/dist/cli/{chunk-AEMPAR6L.js → chunk-DS455RPF.js} +3 -3
- package/dist/cli/{chunk-G7N2DYQL.mjs → chunk-EDMCD7MX.mjs} +5 -5
- package/dist/cli/{chunk-QCIG6V26.mjs → chunk-EGHYGTJM.mjs} +1 -1
- package/dist/cli/{chunk-LMLN7R7X.mjs → chunk-FAZTLYJO.mjs} +2 -2
- package/dist/cli/{chunk-EC2QPBSZ.mjs → chunk-FGEC5SWP.mjs} +4 -4
- package/dist/cli/{chunk-5MHCTVMM.mjs → chunk-FK47YUPC.mjs} +1 -1
- package/dist/cli/{chunk-Y6OKWGAM.mjs → chunk-GGJQ4HJW.mjs} +2 -2
- package/dist/cli/{chunk-OO6HA5OT.js → chunk-GONUMUBM.js} +7 -7
- package/dist/cli/{chunk-BK3XMHPF.mjs → chunk-GRE3ID5E.mjs} +1 -1
- package/dist/cli/{chunk-SKBXTN5F.mjs → chunk-IEV5UWPN.mjs} +1 -1
- package/dist/cli/chunk-ISP7ZENV.mjs +200 -0
- package/dist/cli/{chunk-7SZUHFJ6.mjs → chunk-J7S3DJB4.mjs} +2 -2
- package/dist/cli/{chunk-AJT436SK.mjs → chunk-JJSLEMQQ.mjs} +1 -1
- package/dist/cli/{chunk-2KC3MJP5.mjs → chunk-JYEZ6BWX.mjs} +2 -2
- package/dist/cli/{chunk-BHID34HA.js → chunk-MYB6JVSD.js} +16 -16
- package/dist/cli/{chunk-AZRG5NWV.mjs → chunk-NREZRYPU.mjs} +2 -2
- package/dist/cli/{chunk-4V34YMLU.js → chunk-PHDEQ6W3.js} +6 -6
- package/dist/cli/{chunk-FKGA7VKL.mjs → chunk-PRL7EKJZ.mjs} +4 -4
- package/dist/cli/{chunk-YT6GV6RP.js → chunk-QSYA6VE4.js} +2 -2
- package/dist/cli/{chunk-FUVJPW7O.js → chunk-R2OR4RHV.js} +8 -8
- package/dist/cli/{chunk-DM7APZWK.mjs → chunk-S24CK3CJ.mjs} +2 -2
- package/dist/cli/{chunk-KDJZXX7I.mjs → chunk-SCPFOH5Z.mjs} +1 -1
- package/dist/cli/{chunk-6NF7S5WY.js → chunk-T5GZZJ7O.js} +6 -6
- package/dist/cli/{chunk-HYS35M6H.mjs → chunk-UDF2CY4D.mjs} +10 -10
- package/dist/cli/{chunk-ETJSPSOQ.js → chunk-UGBZ6MCR.js} +2 -2
- package/dist/cli/{chunk-MFNEJOQG.js → chunk-UY7OXFVU.js} +10 -10
- package/dist/cli/{chunk-2ZIUCN5I.js → chunk-VFEW53L5.js} +93 -93
- package/dist/cli/{chunk-VU2PUAEH.js → chunk-WI2HNYQX.js} +53 -53
- package/dist/cli/{chunk-AZUDSDZX.js → chunk-WKB6Y43W.js} +37 -37
- package/dist/cli/chunk-XRIQN6EP.js +200 -0
- package/dist/cli/{chunk-FQFAWIRK.mjs → chunk-YL64JIQ7.mjs} +1 -1
- package/dist/cli/{csv-IC3XJ4PV.mjs → csv-DIFVIR23.mjs} +4 -4
- package/dist/cli/{csv-UWFQLI3K.js → csv-EKEFLUIW.js} +13 -13
- package/dist/cli/{db-RIPJQYF3.mjs → db-DOW4EVEU.mjs} +6 -6
- package/dist/cli/{db-PT73YDEP.js → db-S7DDRUHX.js} +27 -27
- package/dist/cli/{describe-GHI2MTDW.mjs → describe-KSZFOWKV.mjs} +18 -17
- package/dist/cli/describe-RXYQCJRR.js +49 -0
- package/dist/cli/{executions-QUOWVXCU.js → executions-3DU5IXB6.js} +8 -8
- package/dist/cli/{executions-XUJBZF5H.mjs → executions-CAG7YC5K.mjs} +6 -6
- package/dist/cli/{feedback-JOZ7QNGH.mjs → feedback-BQMPTE47.mjs} +4 -4
- package/dist/cli/{feedback-UDZ7BFB3.js → feedback-I65JMCP2.js} +8 -8
- package/dist/cli/git-ADIABNMQ.js +25 -0
- package/dist/cli/{git-O67OED4L.mjs → git-UQUCD7XZ.mjs} +5 -5
- package/dist/cli/index.js +138 -138
- package/dist/cli/index.mjs +42 -42
- package/dist/cli/{legacy-noops-T2G2TKO2.mjs → legacy-noops-JXKLHUI3.mjs} +5 -5
- package/dist/cli/{legacy-noops-ZFD6Z2ID.js → legacy-noops-OLNT2BG5.js} +8 -8
- package/dist/cli/{monitors-WSH4I37O.mjs → monitors-DLTHHAFQ.mjs} +7 -7
- package/dist/cli/{monitors-QPWEWJW7.js → monitors-Z5X56AZN.js} +91 -91
- package/dist/cli/{org-FVM465Q4.mjs → org-6EZZHD3M.mjs} +6 -6
- package/dist/cli/{org-PZOFC4P3.js → org-XBHJLKUG.js} +72 -72
- package/dist/cli/{pages-A5SLKL6L.mjs → pages-MYXROSVK.mjs} +6 -6
- package/dist/cli/{pages-UMDOU2WF.js → pages-XVJ34SCN.js} +17 -17
- package/dist/cli/{play-XKJLIZQE.mjs → play-5PV4LAHE.mjs} +26 -22
- package/dist/cli/{play-AFGL5D7B.js → play-ACC4T2XQ.js} +495 -491
- package/dist/cli/{providers-A2EIHS3P.mjs → providers-2DLUGIFF.mjs} +6 -6
- package/dist/cli/{providers-CQDRM62K.js → providers-JCI3KNE4.js} +9 -9
- package/dist/cli/{quickstart-BJ2XCUVV.mjs → quickstart-NSL3C76K.mjs} +4 -4
- package/dist/cli/{quickstart-NMJLH7T6.js → quickstart-PDSQEDLD.js} +6 -6
- package/dist/cli/{run-S4XTJADQ.js → run-UCFMHOQC.js} +37 -36
- package/dist/cli/{run-63I5M3ID.mjs → run-X5MXCM4P.mjs} +26 -25
- package/dist/cli/{search-DUIWWZ56.mjs → search-RPEMXV6N.mjs} +8 -8
- package/dist/cli/search-YILJZD36.js +32 -0
- package/dist/cli/{chunk-EDBQIPMG.mjs → search-output-6UO47B7G.mjs} +14 -194
- package/dist/cli/{chunk-UXQZLXHZ.js → search-output-MZH3HLVE.js} +14 -194
- package/dist/cli/{secrets-FK4PQJ6U.mjs → secrets-NLEQURD3.mjs} +6 -6
- package/dist/cli/{secrets-Q6QEWCAT.js → secrets-UFBASYGY.js} +15 -15
- package/dist/cli/{sessions-QJSN6AUL.mjs → sessions-3ALFLWVU.mjs} +5 -5
- package/dist/cli/{sessions-KF6JPKFK.js → sessions-JYH4DBEE.js} +6 -6
- package/dist/cli/{settings-PIKGA5PF.js → settings-MQYKNAMB.js} +78 -78
- package/dist/cli/{settings-UIQP5ERC.mjs → settings-YPRILREA.mjs} +11 -11
- package/dist/cli/{setup-ROKA4M5X.js → setup-5IGSHH4E.js} +47 -47
- package/dist/cli/{setup-4CALCNAA.mjs → setup-DK4GM227.mjs} +9 -9
- package/dist/cli/skills-I4IUZN3U.js +33 -0
- package/dist/cli/{skills-SQKRC7W4.mjs → skills-KYBZH3IT.mjs} +7 -7
- package/dist/cli/{tools-B6J53QS2.mjs → tools-4B2MHNBN.mjs} +17 -16
- package/dist/cli/tools-NLZR7ABS.js +56 -0
- package/dist/cli/update-RVDEUJTE.js +33 -0
- package/dist/cli/{update-MVKCAJJV.mjs → update-S6VEO7NB.mjs} +9 -9
- package/dist/cli/{workflow-VH2H4VS3.js → workflow-FU2XVPUK.js} +17 -17
- package/dist/cli/{workflow-3BO5WPZO.mjs → workflow-KXZZYFEF.mjs} +7 -7
- package/dist/index.js +10 -10
- package/dist/index.mjs +10 -10
- package/dist/install-integrity.json +100 -96
- package/dist/plays/bundle-play-file.mjs +6 -6
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +2 -2
- package/dist/release.mjs +1 -1
- package/dist/server.js +5 -5
- package/dist/server.mjs +3 -3
- package/package.json +1 -1
- package/dist/cli/auth-Q5VRDGL4.js +0 -43
- package/dist/cli/describe-72RFB7RS.js +0 -48
- package/dist/cli/git-A6SU7ITW.js +0 -25
- package/dist/cli/search-ACCI4VYH.js +0 -32
- package/dist/cli/skills-GZQSDPZX.js +0 -33
- package/dist/cli/tools-5C7ZVTDG.js +0 -55
- package/dist/cli/update-PR4QP7JN.js +0 -33
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; } var _class; var _class2;require('./chunk-I5YZLGMG.js');
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('./chunk-
|
|
4
|
+
var _chunk2MKX3HV3js = require('./chunk-2MKX3HV3.js');
|
|
5
|
+
require('./chunk-T5GZZJ7O.js');
|
|
6
6
|
require('./chunk-E4CABWXL.js');
|
|
7
7
|
require('./chunk-GVAENVIG.js');
|
|
8
8
|
require('./chunk-NMU3VR5U.js');
|
|
@@ -17,15 +17,15 @@ require('./chunk-UNEMDKXN.js');
|
|
|
17
17
|
var _chunkIF75RD6Ujs = require('./chunk-IF75RD6U.js');
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _chunkDS455RPFjs = require('./chunk-DS455RPF.js');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
27
|
-
require('./chunk-
|
|
28
|
-
require('./chunk-
|
|
26
|
+
var _chunkGONUMUBMjs = require('./chunk-GONUMUBM.js');
|
|
27
|
+
require('./chunk-5LHU7NUS.js');
|
|
28
|
+
require('./chunk-75IIHFN6.js');
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
var _chunkALJJRZNJjs = require('./chunk-ALJJRZNJ.js');
|
|
@@ -33,7 +33,7 @@ require('./chunk-XNYIZMNQ.js');
|
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
var _chunkDIAWYWT5js = require('./chunk-DIAWYWT5.js');
|
|
36
|
-
require('./chunk-
|
|
36
|
+
require('./chunk-2JWG2H2N.js');
|
|
37
37
|
require('./chunk-OG64RBAC.js');
|
|
38
38
|
require('./chunk-COGTRVWW.js');
|
|
39
39
|
|
|
@@ -111,10 +111,10 @@ function reportMonitorsFailure(error, options) {
|
|
|
111
111
|
const exitCode = monitorsErrorExitCode(error);
|
|
112
112
|
const next = monitorsFailureNextCommand(error, exitCode, options);
|
|
113
113
|
const retrySafe = exitCode === 5 && _optionalChain([options, 'optionalAccess', _9 => _9.retryCommand]) !== void 0;
|
|
114
|
-
const wantsJson =
|
|
114
|
+
const wantsJson = _chunkGONUMUBMjs.shouldEmitJson.call(void 0, process.argv.includes("--json"));
|
|
115
115
|
if (wantsJson) {
|
|
116
|
-
const payload =
|
|
117
|
-
|
|
116
|
+
const payload = _chunkGONUMUBMjs.errorToJsonPayload.call(void 0, error);
|
|
117
|
+
_chunkGONUMUBMjs.printJson.call(void 0, {
|
|
118
118
|
ok: false,
|
|
119
119
|
exitCode,
|
|
120
120
|
...next ? { next } : {},
|
|
@@ -529,14 +529,14 @@ Preview the plan first with:
|
|
|
529
529
|
);
|
|
530
530
|
}
|
|
531
531
|
async function handleMonitorsStatus(options) {
|
|
532
|
-
const payload = await new (0,
|
|
532
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.status();
|
|
533
533
|
const hasAccess = payload.has_access === true;
|
|
534
534
|
const reason = typeof payload.reason === "string" && payload.reason.trim() ? payload.reason.trim() : void 0;
|
|
535
535
|
const text = hasAccess ? `\u2713 You have access to Deepline Monitors${reason ? `
|
|
536
536
|
${reason}` : ""}
|
|
537
537
|
` : `\u2717 No access to Deepline Monitors${reason ? ` \u2014 ${reason}` : ""}
|
|
538
538
|
`;
|
|
539
|
-
|
|
539
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
540
540
|
{ has_access: hasAccess, ...reason ? { reason } : {} },
|
|
541
541
|
{ json: options.json, text }
|
|
542
542
|
);
|
|
@@ -602,14 +602,14 @@ async function handleMonitorsAvailable(toolId, options) {
|
|
|
602
602
|
}
|
|
603
603
|
}
|
|
604
604
|
const tool = _nullishCoalesce(toolId, () => ( options.tool));
|
|
605
|
-
const payload = await new (0,
|
|
605
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.available(tool, {
|
|
606
606
|
...options.provider ? { provider: options.provider } : {},
|
|
607
607
|
...options.search ? { search: options.search } : {},
|
|
608
608
|
...options.limit ? { limit: options.limit } : {},
|
|
609
609
|
...options.full ? { full: true } : {},
|
|
610
610
|
...options.compact ? { compact: true } : {}
|
|
611
611
|
});
|
|
612
|
-
|
|
612
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
613
613
|
json: options.json,
|
|
614
614
|
// Human list view shows id + name + deployed_count ("deployed: N") so
|
|
615
615
|
// can-deploy vs already-deployed is visible in one view. Describing a
|
|
@@ -712,14 +712,14 @@ async function handleMonitorsList(options) {
|
|
|
712
712
|
"`--compact` is deprecated and now does nothing; returning the complete monitor records.\n"
|
|
713
713
|
);
|
|
714
714
|
}
|
|
715
|
-
const payload = await new (0,
|
|
715
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.list({
|
|
716
716
|
...state ? { state } : {},
|
|
717
717
|
...options.status ? { status: options.status } : {},
|
|
718
718
|
...options.limit ? { limit: options.limit } : {},
|
|
719
719
|
...options.cursor ? { cursor: options.cursor } : {},
|
|
720
720
|
...options.includeConsumers ? { includeConsumers: true } : {}
|
|
721
721
|
});
|
|
722
|
-
|
|
722
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
723
723
|
json: options.json,
|
|
724
724
|
text: renderDeployedListText(
|
|
725
725
|
payload,
|
|
@@ -735,10 +735,10 @@ async function handleMonitorsCheck(definition, options) {
|
|
|
735
735
|
argLabel: "<definition>",
|
|
736
736
|
command: "deepline monitors check"
|
|
737
737
|
});
|
|
738
|
-
const payload = await new (0,
|
|
738
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.check(
|
|
739
739
|
body
|
|
740
740
|
);
|
|
741
|
-
|
|
741
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
742
742
|
}
|
|
743
743
|
function previewText(value) {
|
|
744
744
|
return typeof value === "string" && value.trim() ? value.trim() : "-";
|
|
@@ -796,22 +796,22 @@ async function handleMonitorsPreview(definition, options) {
|
|
|
796
796
|
if (limit !== void 0 && !Number.isInteger(limit)) {
|
|
797
797
|
throw new MonitorsUsageError("--limit must be a whole number from 1 to 3.");
|
|
798
798
|
}
|
|
799
|
-
const wantsJson =
|
|
799
|
+
const wantsJson = _chunkGONUMUBMjs.shouldEmitJson.call(void 0, options.json);
|
|
800
800
|
if (options.idempotencyKey === void 0 && wantsJson) {
|
|
801
801
|
throw new MonitorsUsageError(
|
|
802
802
|
"--json requires --idempotency-key <key>. Choose a new key for each new preview and keep it: rerunning with the same key returns the result without paying again."
|
|
803
803
|
);
|
|
804
804
|
}
|
|
805
805
|
const idempotencyKey = _nullishCoalesce(options.idempotencyKey, () => ( `monitor-preview-${_crypto.randomUUID.call(void 0, )}`));
|
|
806
|
-
const progress =
|
|
806
|
+
const progress = _chunkDS455RPFjs.createCliProgress.call(void 0, !wantsJson);
|
|
807
807
|
progress.phase(`Preview key: ${idempotencyKey}`);
|
|
808
808
|
try {
|
|
809
|
-
const payload = await new (0,
|
|
809
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.preview(
|
|
810
810
|
body,
|
|
811
811
|
{ idempotencyKey, ...limit === void 0 ? {} : { limit } }
|
|
812
812
|
);
|
|
813
813
|
progress.complete();
|
|
814
|
-
|
|
814
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
815
815
|
json: options.json,
|
|
816
816
|
text: renderMonitorPreviewText(payload)
|
|
817
817
|
});
|
|
@@ -856,7 +856,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
856
856
|
argLabel: "<definition>",
|
|
857
857
|
command: "deepline monitors deploy"
|
|
858
858
|
});
|
|
859
|
-
const client = new (0,
|
|
859
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
860
860
|
const definitionArg = body;
|
|
861
861
|
if (options.dryRun) {
|
|
862
862
|
const payload2 = await client.monitors.deploy(definitionArg, {
|
|
@@ -864,7 +864,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
864
864
|
});
|
|
865
865
|
const valid = payload2.valid !== false;
|
|
866
866
|
const hasIdentityConflict = Boolean(_optionalChain([asRecord, 'call', _23 => _23(payload2), 'optionalAccess', _24 => _24.identity_conflict]));
|
|
867
|
-
|
|
867
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
868
868
|
{ dry_run: true, ...payload2 },
|
|
869
869
|
{ json: options.json, text: renderMonitorDeployPlan(payload2) }
|
|
870
870
|
);
|
|
@@ -874,7 +874,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
874
874
|
return;
|
|
875
875
|
}
|
|
876
876
|
const payload = await client.monitors.deploy(definitionArg);
|
|
877
|
-
|
|
877
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
878
878
|
json: options.json,
|
|
879
879
|
text: renderMonitorDeployCompletion(payload)
|
|
880
880
|
});
|
|
@@ -886,29 +886,29 @@ async function handleMonitorsSync(definition, options) {
|
|
|
886
886
|
argLabel: "<definition>",
|
|
887
887
|
command: "deepline monitors sync"
|
|
888
888
|
});
|
|
889
|
-
const payload = await new (0,
|
|
889
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.sync(body, {
|
|
890
890
|
...options.dryRun ? { dryRun: true } : {},
|
|
891
891
|
idempotencyKey: _nullishCoalesce(options.idempotencyKey, () => ( monitorJobIdempotencyKey("scalar-sync", void 0)))
|
|
892
892
|
});
|
|
893
893
|
if (options.dryRun) {
|
|
894
894
|
const plan = payload;
|
|
895
|
-
|
|
895
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
896
896
|
{ dry_run: true, ...plan },
|
|
897
897
|
{ json: options.json, text: renderMonitorDeployPlan(plan) }
|
|
898
898
|
);
|
|
899
899
|
return;
|
|
900
900
|
}
|
|
901
|
-
|
|
901
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
902
902
|
json: options.json,
|
|
903
903
|
text: renderMonitorJob(payload)
|
|
904
904
|
});
|
|
905
905
|
}
|
|
906
906
|
async function handleScalarMonitorLifecycle(action, key, options) {
|
|
907
|
-
const payload = await new (0,
|
|
907
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors[action](key, {
|
|
908
908
|
...options.dryRun ? { dryRun: true } : {},
|
|
909
909
|
idempotencyKey: _nullishCoalesce(options.idempotencyKey, () => ( monitorJobIdempotencyKey(`${action}-${key}`, void 0)))
|
|
910
910
|
});
|
|
911
|
-
|
|
911
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
912
912
|
json: options.json,
|
|
913
913
|
text: options.dryRun ? void 0 : renderMonitorJob(payload)
|
|
914
914
|
});
|
|
@@ -997,11 +997,11 @@ async function handleMonitorJobBatchDeploy(options, idempotencyKey) {
|
|
|
997
997
|
lint.issues.filter((issue) => issue.severity === "error").map((issue) => `${issue.path || "batch"}: ${issue.message}`).join("; ")
|
|
998
998
|
);
|
|
999
999
|
}
|
|
1000
|
-
const payload = await new (0,
|
|
1000
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batch.deploy(
|
|
1001
1001
|
lint.normalized.monitors,
|
|
1002
1002
|
{ idempotencyKey }
|
|
1003
1003
|
);
|
|
1004
|
-
|
|
1004
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1005
1005
|
{
|
|
1006
1006
|
...payload,
|
|
1007
1007
|
idempotency_key: idempotencyKey,
|
|
@@ -1034,7 +1034,7 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
1034
1034
|
);
|
|
1035
1035
|
}
|
|
1036
1036
|
if (options.dryRun) {
|
|
1037
|
-
|
|
1037
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1038
1038
|
{
|
|
1039
1039
|
ok: true,
|
|
1040
1040
|
dry_run: true,
|
|
@@ -1051,7 +1051,7 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
1051
1051
|
"sync",
|
|
1052
1052
|
options.idempotencyKey
|
|
1053
1053
|
);
|
|
1054
|
-
const payload = await new (0,
|
|
1054
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batches.sync(
|
|
1055
1055
|
batchId,
|
|
1056
1056
|
lint.normalized.monitors,
|
|
1057
1057
|
{
|
|
@@ -1059,14 +1059,14 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
1059
1059
|
...parsedGeneration === void 0 ? {} : { expectedGeneration: parsedGeneration }
|
|
1060
1060
|
}
|
|
1061
1061
|
);
|
|
1062
|
-
|
|
1062
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1063
1063
|
{ ...payload, idempotency_key: idempotencyKey },
|
|
1064
1064
|
{ json: options.json, text: renderMonitorJob(payload) }
|
|
1065
1065
|
);
|
|
1066
1066
|
}
|
|
1067
1067
|
async function handleNamedMonitorBatchLifecycle(batchId, intent, options) {
|
|
1068
1068
|
if (options.dryRun) {
|
|
1069
|
-
|
|
1069
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1070
1070
|
{
|
|
1071
1071
|
ok: true,
|
|
1072
1072
|
dry_run: true,
|
|
@@ -1082,17 +1082,17 @@ async function handleNamedMonitorBatchLifecycle(batchId, intent, options) {
|
|
|
1082
1082
|
intent,
|
|
1083
1083
|
options.idempotencyKey
|
|
1084
1084
|
);
|
|
1085
|
-
const payload = await new (0,
|
|
1085
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batches[intent](batchId, {
|
|
1086
1086
|
idempotencyKey
|
|
1087
1087
|
});
|
|
1088
|
-
|
|
1088
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1089
1089
|
{ ...payload, idempotency_key: idempotencyKey },
|
|
1090
1090
|
{ json: options.json, text: renderMonitorJob(payload) }
|
|
1091
1091
|
);
|
|
1092
1092
|
}
|
|
1093
1093
|
async function handleNamedMonitorBatchGet(batchId, options) {
|
|
1094
|
-
const payload = await new (0,
|
|
1095
|
-
|
|
1094
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batches.get(batchId);
|
|
1095
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
1096
1096
|
json: options.json,
|
|
1097
1097
|
text: renderMonitorJob(payload)
|
|
1098
1098
|
});
|
|
@@ -1106,7 +1106,7 @@ async function handleMonitorBatchLint(options) {
|
|
|
1106
1106
|
const result = _chunkIF75RD6Ujs.lintMonitorBatchInput.call(void 0,
|
|
1107
1107
|
readMonitorDefinitionsJsonFile(options.file)
|
|
1108
1108
|
);
|
|
1109
|
-
|
|
1109
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1110
1110
|
{
|
|
1111
1111
|
ok: !result.issues.some((issue) => issue.severity === "error"),
|
|
1112
1112
|
...result.normalized ? { normalized: result.normalized } : {},
|
|
@@ -1126,7 +1126,7 @@ async function handleMonitorFleetLint(options) {
|
|
|
1126
1126
|
const result = _chunkC374C22Yjs.lintMonitorFleetInput.call(void 0,
|
|
1127
1127
|
readMonitorDefinitionsJsonFile(options.file)
|
|
1128
1128
|
);
|
|
1129
|
-
|
|
1129
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1130
1130
|
{
|
|
1131
1131
|
ok: !result.issues.some((issue) => issue.severity === "error"),
|
|
1132
1132
|
...result.normalized ? { normalized: result.normalized } : {},
|
|
@@ -1138,32 +1138,32 @@ async function handleMonitorFleetLint(options) {
|
|
|
1138
1138
|
process.exitCode = 2;
|
|
1139
1139
|
}
|
|
1140
1140
|
async function handleMonitorJobGet(jobId, options) {
|
|
1141
|
-
const payload = await new (0,
|
|
1142
|
-
|
|
1141
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.jobs.get(jobId);
|
|
1142
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
1143
1143
|
json: options.json,
|
|
1144
1144
|
text: renderMonitorJob(payload)
|
|
1145
1145
|
});
|
|
1146
1146
|
}
|
|
1147
1147
|
async function handleMonitorJobWait(jobId, options) {
|
|
1148
|
-
const payload = await new (0,
|
|
1148
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.jobs.wait(jobId, {
|
|
1149
1149
|
timeoutMs: fleetTimeoutMs(options.timeout),
|
|
1150
1150
|
pollIntervalMs: FLEET_POLL_INTERVAL_MS
|
|
1151
1151
|
});
|
|
1152
|
-
|
|
1152
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
1153
1153
|
json: options.json,
|
|
1154
1154
|
text: renderMonitorJob(payload)
|
|
1155
1155
|
});
|
|
1156
1156
|
}
|
|
1157
1157
|
async function handleMonitorJobLogs(jobId, options) {
|
|
1158
1158
|
const limit = options.limit ? fleetIntegerOption(options.limit, "--limit") : void 0;
|
|
1159
|
-
const payload = await new (0,
|
|
1159
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.jobs.logs(jobId, {
|
|
1160
1160
|
...limit === void 0 ? {} : { limit }
|
|
1161
1161
|
});
|
|
1162
|
-
|
|
1162
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
1163
1163
|
}
|
|
1164
1164
|
async function handleMonitorJobCancel(jobId, options) {
|
|
1165
|
-
const payload = await new (0,
|
|
1166
|
-
|
|
1165
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.jobs.cancel(jobId);
|
|
1166
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, {
|
|
1167
1167
|
json: options.json,
|
|
1168
1168
|
text: renderMonitorJob(payload)
|
|
1169
1169
|
});
|
|
@@ -1472,7 +1472,7 @@ function renderFleetDeactivatePlan(payload, fleetId) {
|
|
|
1472
1472
|
`;
|
|
1473
1473
|
}
|
|
1474
1474
|
function reportFleetState(payload, error, options) {
|
|
1475
|
-
|
|
1475
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1476
1476
|
{
|
|
1477
1477
|
...payload,
|
|
1478
1478
|
code: error.code,
|
|
@@ -1587,7 +1587,7 @@ async function handleMonitorFleetsInit(fleetId, options) {
|
|
|
1587
1587
|
_fs.writeFileSync.call(void 0, file, `${JSON.stringify(definition, null, 2)}
|
|
1588
1588
|
`, "utf8");
|
|
1589
1589
|
const next = `deepline monitors fleets deploy --file ${fleetShellArg(file)} --dry-run`;
|
|
1590
|
-
|
|
1590
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1591
1591
|
{ schemaVersion: 2, file, definition, next },
|
|
1592
1592
|
{
|
|
1593
1593
|
json: options.json,
|
|
@@ -1649,7 +1649,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1649
1649
|
'The Fleet definition has no id. Add a top-level "id" and re-run.'
|
|
1650
1650
|
);
|
|
1651
1651
|
}
|
|
1652
|
-
const client = new (0,
|
|
1652
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
1653
1653
|
const payload = await client.monitors.fleets.sync(
|
|
1654
1654
|
_nullishCoalesce(definition, () => ( fleetId)),
|
|
1655
1655
|
{
|
|
@@ -1671,7 +1671,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1671
1671
|
}
|
|
1672
1672
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1673
1673
|
if (!options.wait || options.dryRun) {
|
|
1674
|
-
|
|
1674
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1675
1675
|
json: options.json,
|
|
1676
1676
|
text: renderFleetSync(payload, {
|
|
1677
1677
|
fleetId,
|
|
@@ -1697,7 +1697,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1697
1697
|
const status = fleetStatus(final);
|
|
1698
1698
|
const summary = renderFleetGet(final);
|
|
1699
1699
|
if (status === "converged") {
|
|
1700
|
-
|
|
1700
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text: summary });
|
|
1701
1701
|
return;
|
|
1702
1702
|
}
|
|
1703
1703
|
const driftCommand = `deepline monitors fleets get ${fleetShellArg(fleetId)} --drift`;
|
|
@@ -1730,14 +1730,14 @@ async function handleMonitorFleetsGet(fleetId, options) {
|
|
|
1730
1730
|
);
|
|
1731
1731
|
}
|
|
1732
1732
|
const limit = options.limit === void 0 ? void 0 : fleetIntegerOption(options.limit, "--limit");
|
|
1733
|
-
const client = new (0,
|
|
1733
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
1734
1734
|
const payload = await client.monitors.fleets.get(fleetId, {
|
|
1735
1735
|
...options.drift ? { drift: true } : {},
|
|
1736
1736
|
...limit !== void 0 ? { limit } : {}
|
|
1737
1737
|
});
|
|
1738
1738
|
const text = fleetId ? renderFleetGet(payload) : renderFleetList(payload);
|
|
1739
1739
|
if (!options.check) {
|
|
1740
|
-
|
|
1740
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json, text });
|
|
1741
1741
|
return;
|
|
1742
1742
|
}
|
|
1743
1743
|
const statuses = fleetId ? [fleetStatus(payload)] : (Array.isArray(payload.fleets) ? payload.fleets : []).map(
|
|
@@ -1745,7 +1745,7 @@ async function handleMonitorFleetsGet(fleetId, options) {
|
|
|
1745
1745
|
);
|
|
1746
1746
|
const unconverged = statuses.filter((status) => status !== "converged");
|
|
1747
1747
|
if (unconverged.length === 0) {
|
|
1748
|
-
|
|
1748
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json, text });
|
|
1749
1749
|
return;
|
|
1750
1750
|
}
|
|
1751
1751
|
const target = _nullishCoalesce(fleetId, () => ( "<fleet-id>"));
|
|
@@ -1784,13 +1784,13 @@ async function handleMonitorFleetsReactivate(fleetId, options, idempotencyKey) {
|
|
|
1784
1784
|
${fleetReactivateCommandLine(fleetId, options)}`
|
|
1785
1785
|
);
|
|
1786
1786
|
}
|
|
1787
|
-
const client = new (0,
|
|
1787
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
1788
1788
|
const payload = await client.monitors.fleets.reactivate(fleetId, {
|
|
1789
1789
|
idempotencyKey
|
|
1790
1790
|
});
|
|
1791
1791
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1792
1792
|
if (!options.wait) {
|
|
1793
|
-
|
|
1793
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1794
1794
|
json: options.json,
|
|
1795
1795
|
text: `Fleet ${fleetId} \u2014 ${readMonitorState(payload) ? `state ${readMonitorState(payload)}` : "reactivation accepted"}
|
|
1796
1796
|
idempotency key ${idempotencyKey}
|
|
@@ -1813,7 +1813,7 @@ async function handleMonitorFleetsReactivate(fleetId, options, idempotencyKey) {
|
|
|
1813
1813
|
const envelope = { ...accepted, ...final };
|
|
1814
1814
|
const text = renderFleetGet(final);
|
|
1815
1815
|
if (fleetStatus(final) === "converged") {
|
|
1816
|
-
|
|
1816
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text });
|
|
1817
1817
|
return;
|
|
1818
1818
|
}
|
|
1819
1819
|
reportFleetState(
|
|
@@ -1855,7 +1855,7 @@ async function confirmFleetDeactivate(fleetId, plan) {
|
|
|
1855
1855
|
}
|
|
1856
1856
|
}
|
|
1857
1857
|
async function handleMonitorFleetsDeactivate(fleetId, options, idempotencyKey) {
|
|
1858
|
-
const client = new (0,
|
|
1858
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
1859
1859
|
if (options.dryRun) {
|
|
1860
1860
|
const plan = await client.monitors.fleets.deactivate(fleetId, {
|
|
1861
1861
|
dryRun: true,
|
|
@@ -1865,7 +1865,7 @@ async function handleMonitorFleetsDeactivate(fleetId, options, idempotencyKey) {
|
|
|
1865
1865
|
command: "deepline monitors fleets deactivate",
|
|
1866
1866
|
mutation: "fleet deactivate"
|
|
1867
1867
|
});
|
|
1868
|
-
|
|
1868
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, plan, {
|
|
1869
1869
|
json: options.json,
|
|
1870
1870
|
text: renderFleetDeactivatePlan(plan, fleetId)
|
|
1871
1871
|
});
|
|
@@ -1903,7 +1903,7 @@ Preview the blast radius first:
|
|
|
1903
1903
|
});
|
|
1904
1904
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1905
1905
|
if (payload.already === true) {
|
|
1906
|
-
|
|
1906
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1907
1907
|
json: options.json,
|
|
1908
1908
|
text: `Fleet ${fleetId} is already deactivated.
|
|
1909
1909
|
`
|
|
@@ -1915,7 +1915,7 @@ Preview the blast radius first:
|
|
|
1915
1915
|
` + (fleetServerNext(payload) ? `Next: ${fleetServerNext(payload)}
|
|
1916
1916
|
` : "");
|
|
1917
1917
|
if (!options.wait) {
|
|
1918
|
-
|
|
1918
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1919
1919
|
json: options.json,
|
|
1920
1920
|
text: acceptedText
|
|
1921
1921
|
});
|
|
@@ -1937,7 +1937,7 @@ Preview the blast radius first:
|
|
|
1937
1937
|
const envelope = { ...accepted, ...final };
|
|
1938
1938
|
const summary = renderFleetGet(final);
|
|
1939
1939
|
if (fleetStatus(final) === "deactivated") {
|
|
1940
|
-
|
|
1940
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text: summary });
|
|
1941
1941
|
return;
|
|
1942
1942
|
}
|
|
1943
1943
|
reportFleetState(
|
|
@@ -1968,7 +1968,7 @@ function handleMonitorFleetsOverview(options) {
|
|
|
1968
1968
|
"Agent notes:",
|
|
1969
1969
|
...MONITOR_FLEET_AGENT_NOTES.map((note) => ` ${note}`)
|
|
1970
1970
|
];
|
|
1971
|
-
|
|
1971
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
1972
1972
|
{
|
|
1973
1973
|
schemaVersion: 1,
|
|
1974
1974
|
lifecycle: MONITOR_FLEET_LIFECYCLE,
|
|
@@ -2129,7 +2129,7 @@ function renderMonitorGet(payload) {
|
|
|
2129
2129
|
`;
|
|
2130
2130
|
}
|
|
2131
2131
|
async function handleMonitorsGet(key, options) {
|
|
2132
|
-
const client = new (0,
|
|
2132
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
2133
2133
|
const payload = await client.monitors.get(key);
|
|
2134
2134
|
const boundPlays = Array.isArray(payload.bound_plays) ? payload.bound_plays : null;
|
|
2135
2135
|
const dependents = boundPlays ? {
|
|
@@ -2137,24 +2137,24 @@ async function handleMonitorsGet(key, options) {
|
|
|
2137
2137
|
truncated: payload.consumer_health_truncated === true
|
|
2138
2138
|
} : await client.monitors.dependents(key);
|
|
2139
2139
|
const detail = { ...payload, dependents };
|
|
2140
|
-
|
|
2140
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, detail, {
|
|
2141
2141
|
json: options.json,
|
|
2142
2142
|
text: renderMonitorGet(detail)
|
|
2143
2143
|
});
|
|
2144
2144
|
}
|
|
2145
2145
|
async function handleMonitorsTest(key, payload, options) {
|
|
2146
2146
|
const explicitPayload = parseJsonObjectArg(payload, "<payload>");
|
|
2147
|
-
const result = await new (0,
|
|
2147
|
+
const result = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.test(key, explicitPayload);
|
|
2148
2148
|
const text = `Monitor diagnostic for ${key}: ${result.accepted === true ? "accepted" : "rejected"}
|
|
2149
2149
|
mode: validation_only (no rows written, credits spent, or Plays dispatched)
|
|
2150
2150
|
persisted rows: ${_nullishCoalesce(asFiniteNumber(result.persisted_rows), () => ( 0))}
|
|
2151
2151
|
dispatched bound Plays: ${_nullishCoalesce(asFiniteNumber(result.dispatched_bound_plays), () => ( 0))}
|
|
2152
2152
|
`;
|
|
2153
|
-
|
|
2153
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, result, { json: options.json, text });
|
|
2154
2154
|
}
|
|
2155
2155
|
async function handleMonitorsValidate(key, options) {
|
|
2156
|
-
const result = await new (0,
|
|
2157
|
-
|
|
2156
|
+
const result = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.validate(key);
|
|
2157
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, result, { json: options.json });
|
|
2158
2158
|
if (result.valid === false) process.exitCode = 7;
|
|
2159
2159
|
}
|
|
2160
2160
|
async function confirmMonitorDelete(key) {
|
|
@@ -2172,14 +2172,14 @@ async function confirmMonitorDelete(key) {
|
|
|
2172
2172
|
}
|
|
2173
2173
|
}
|
|
2174
2174
|
async function handleMonitorsDelete(key, options) {
|
|
2175
|
-
const client = new (0,
|
|
2175
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
2176
2176
|
if (options.dryRun) {
|
|
2177
2177
|
const payload2 = await client.monitors.delete(key, { dryRun: true });
|
|
2178
2178
|
assertMonitorDryRunAcknowledged(payload2, {
|
|
2179
2179
|
command: "deepline monitors delete",
|
|
2180
2180
|
mutation: "delete"
|
|
2181
2181
|
});
|
|
2182
|
-
|
|
2182
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload2, {
|
|
2183
2183
|
json: options.json,
|
|
2184
2184
|
text: renderMonitorDeletePlan(payload2, key)
|
|
2185
2185
|
});
|
|
@@ -2199,7 +2199,7 @@ async function handleMonitorsDelete(key, options) {
|
|
|
2199
2199
|
}
|
|
2200
2200
|
}
|
|
2201
2201
|
const payload = await client.monitors.delete(key);
|
|
2202
|
-
|
|
2202
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2203
2203
|
}
|
|
2204
2204
|
async function handleMonitorsUpdate(key, patch, options) {
|
|
2205
2205
|
const body = resolveMonitorJsonBody({
|
|
@@ -2208,25 +2208,25 @@ async function handleMonitorsUpdate(key, patch, options) {
|
|
|
2208
2208
|
argLabel: "<patch>",
|
|
2209
2209
|
command: `deepline monitors update ${key}`
|
|
2210
2210
|
});
|
|
2211
|
-
const payload = await new (0,
|
|
2212
|
-
|
|
2211
|
+
const payload = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.update(key, body);
|
|
2212
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2213
2213
|
}
|
|
2214
2214
|
async function handleMonitorsReactivate(key, options) {
|
|
2215
|
-
const client = new (0,
|
|
2215
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
2216
2216
|
if (options.dryRun) {
|
|
2217
2217
|
const payload2 = await client.monitors.reactivate(key, { dryRun: true });
|
|
2218
2218
|
assertMonitorDryRunAcknowledged(payload2, {
|
|
2219
2219
|
command: "deepline monitors reactivate",
|
|
2220
2220
|
mutation: "reactivate"
|
|
2221
2221
|
});
|
|
2222
|
-
|
|
2222
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload2, {
|
|
2223
2223
|
json: options.json,
|
|
2224
2224
|
text: renderMonitorReactivatePlan(payload2, key)
|
|
2225
2225
|
});
|
|
2226
2226
|
return;
|
|
2227
2227
|
}
|
|
2228
2228
|
const payload = await client.monitors.reactivate(key);
|
|
2229
|
-
|
|
2229
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2230
2230
|
}
|
|
2231
2231
|
var MONITOR_VERB_POLL_INTERVAL_MS = 2e3;
|
|
2232
2232
|
function monitorHealthLine(health) {
|
|
@@ -2348,7 +2348,7 @@ function monitorHealthText(health) {
|
|
|
2348
2348
|
`;
|
|
2349
2349
|
}
|
|
2350
2350
|
async function handleMonitorsAudit(options) {
|
|
2351
|
-
const client = new (0,
|
|
2351
|
+
const client = new (0, _chunk2MKX3HV3js.DeeplineClient)();
|
|
2352
2352
|
const fleetId = _optionalChain([options, 'access', _75 => _75.fleet, 'optionalAccess', _76 => _76.trim, 'call', _77 => _77()]) || void 0;
|
|
2353
2353
|
const scope = fleetId ? { fleetId } : {};
|
|
2354
2354
|
let result = await client.monitors.audit(scope);
|
|
@@ -2392,7 +2392,7 @@ async function handleMonitorsAudit(options) {
|
|
|
2392
2392
|
"",
|
|
2393
2393
|
monitorHealthText(health)
|
|
2394
2394
|
].join("\n");
|
|
2395
|
-
|
|
2395
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
2396
2396
|
{ ...result, audit: { ...result.audit, totals }, health },
|
|
2397
2397
|
{ json: options.json, text }
|
|
2398
2398
|
);
|
|
@@ -2405,10 +2405,10 @@ async function handleMonitorsRepair(options) {
|
|
|
2405
2405
|
}
|
|
2406
2406
|
async function handleMonitorsHealth(options) {
|
|
2407
2407
|
const fleetId = _optionalChain([options, 'access', _81 => _81.fleet, 'optionalAccess', _82 => _82.trim, 'call', _83 => _83()]) || void 0;
|
|
2408
|
-
const health = await new (0,
|
|
2408
|
+
const health = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.health(
|
|
2409
2409
|
fleetId ? { fleetId } : {}
|
|
2410
2410
|
);
|
|
2411
|
-
|
|
2411
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, health, {
|
|
2412
2412
|
json: options.json,
|
|
2413
2413
|
text: monitorHealthText(health)
|
|
2414
2414
|
});
|
|
@@ -2482,14 +2482,14 @@ async function handleMonitorBatchDeploy(options) {
|
|
|
2482
2482
|
"deploy",
|
|
2483
2483
|
options.idempotencyKey
|
|
2484
2484
|
);
|
|
2485
|
-
const result = await new (0,
|
|
2485
|
+
const result = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batch.submit({
|
|
2486
2486
|
kind: "deploy",
|
|
2487
2487
|
manifestNdjson,
|
|
2488
2488
|
dryRun: options.dryRun === true,
|
|
2489
2489
|
idempotencyKey
|
|
2490
2490
|
});
|
|
2491
2491
|
const operation = result.operation;
|
|
2492
|
-
|
|
2492
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
2493
2493
|
{ ...result, idempotency_key: idempotencyKey },
|
|
2494
2494
|
{
|
|
2495
2495
|
json: options.json,
|
|
@@ -2517,7 +2517,7 @@ async function handleMonitorBatch(kind, options) {
|
|
|
2517
2517
|
kind,
|
|
2518
2518
|
options.idempotencyKey
|
|
2519
2519
|
);
|
|
2520
|
-
const result = await new (0,
|
|
2520
|
+
const result = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batch.submit({
|
|
2521
2521
|
kind,
|
|
2522
2522
|
scope,
|
|
2523
2523
|
dryRun: options.dryRun === true,
|
|
@@ -2530,14 +2530,14 @@ async function handleMonitorBatch(kind, options) {
|
|
|
2530
2530
|
`state ${operation.state} \xB7 retry key ${idempotencyKey}`,
|
|
2531
2531
|
`inspect: deepline monitors batch get ${operation.runId}`
|
|
2532
2532
|
].join("\n");
|
|
2533
|
-
|
|
2533
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0,
|
|
2534
2534
|
{ ...result, idempotency_key: idempotencyKey },
|
|
2535
2535
|
{ json: options.json, text: `${text}
|
|
2536
2536
|
` }
|
|
2537
2537
|
);
|
|
2538
2538
|
}
|
|
2539
2539
|
async function handleMonitorBatchGet(operationId, options) {
|
|
2540
|
-
const result = await new (0,
|
|
2540
|
+
const result = await new (0, _chunk2MKX3HV3js.DeeplineClient)().monitors.batch.get(operationId, {
|
|
2541
2541
|
...options.cursor ? { cursor: options.cursor } : {}
|
|
2542
2542
|
});
|
|
2543
2543
|
const summary = _nullishCoalesce(result.operation.summary, () => ( {}));
|
|
@@ -2549,7 +2549,7 @@ async function handleMonitorBatchGet(operationId, options) {
|
|
|
2549
2549
|
`results ${result.results.page.length}${result.results.isDone ? "" : " (more; pass --cursor)"}`
|
|
2550
2550
|
] : []
|
|
2551
2551
|
].join("\n");
|
|
2552
|
-
|
|
2552
|
+
_chunkGONUMUBMjs.printCommandEnvelope.call(void 0, result, { json: options.json, text: `${text}
|
|
2553
2553
|
` });
|
|
2554
2554
|
}
|
|
2555
2555
|
function registerMonitorsCommands(program) {
|