deepline 0.3.396 → 0.3.397
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/bundling-sources/shared_libs/play-runtime/fixture-behavior.ts +2 -2
- package/dist/cli/{auth-3LTD62VL.mjs → auth-AZJFXGKP.mjs} +5 -4
- package/dist/cli/auth-CZJQU7B5.js +40 -0
- package/dist/cli/{billing-PA5OXEM5.js → billing-MQV5AGDJ.js} +76 -75
- package/dist/cli/{billing-DP7ZAJBO.mjs → billing-MZAAUHGH.mjs} +5 -4
- package/dist/cli/{chunk-VE3U3SQC.mjs → chunk-2LDADJNO.mjs} +7 -107
- package/dist/cli/{chunk-772W2SAU.js → chunk-3VP34TAU.js} +8 -8
- package/dist/cli/{chunk-QHGPA362.mjs → chunk-4D745XZO.mjs} +6 -108
- package/dist/cli/chunk-7DRPTGCK.js +930 -0
- package/dist/cli/{chunk-NSOTASOP.js → chunk-BQR6UN3C.js} +1 -83
- package/dist/cli/{chunk-RTO5QZWT.js → chunk-DQ65ZVHN.js} +6 -6
- package/dist/cli/{chunk-3T4MCB5R.mjs → chunk-F3BUFYKE.mjs} +89 -969
- package/dist/cli/chunk-FIVKWNMT.mjs +210 -0
- package/dist/cli/{describe-6O2ENKTP.mjs → chunk-HFYQBC2D.mjs} +22 -160
- package/dist/cli/chunk-HGFFYVXN.js +210 -0
- package/dist/cli/{chunk-5WNJF2T3.mjs → chunk-IHG7UAHD.mjs} +1 -83
- package/dist/cli/{chunk-GNN4MY5X.js → chunk-IZ74ABSX.js} +1 -1
- package/dist/cli/{chunk-MR6XCBQJ.mjs → chunk-J7ABTQQ7.mjs} +4 -2
- package/dist/cli/{chunk-2VOLOWYZ.js → chunk-K33MXVXQ.js} +293 -1173
- package/dist/cli/chunk-LJ5747UC.mjs +107 -0
- package/dist/cli/{chunk-NHB5YUCS.mjs → chunk-MRXMMERY.mjs} +1 -1
- package/dist/cli/{chunk-TLQ3FZOC.mjs → chunk-MV7QRALK.mjs} +3 -3
- package/dist/cli/{chunk-AUYXWELC.mjs → chunk-MYPH2LUU.mjs} +2 -2
- package/dist/cli/{chunk-LWERJUKN.js → chunk-NA4T3B62.js} +7 -215
- package/dist/cli/{chunk-23GAA3YO.mjs → chunk-NOX2TCBP.mjs} +1 -1
- package/dist/cli/chunk-OSDXE27V.mjs +88 -0
- package/dist/cli/{chunk-KAEZNPUM.js → chunk-PSGEDGLT.js} +13 -115
- package/dist/cli/chunk-Q2E4E4FJ.js +112 -0
- package/dist/cli/{describe-EFWNECHI.js → chunk-RFG3MRAC.js} +37 -175
- package/dist/cli/{chunk-XKZXO7D3.mjs → chunk-RNSWDKBM.mjs} +1 -1
- package/dist/cli/{chunk-V7UP2F4U.js → chunk-RYW4HPSM.js} +21 -121
- package/dist/cli/{chunk-7Z66NHUC.js → chunk-SO7RUVTY.js} +26 -26
- package/dist/cli/{chunk-H5KLUGY7.mjs → chunk-TXZVVBQZ.mjs} +1 -209
- package/dist/cli/{chunk-WQJJNIMQ.js → chunk-UVXBVUZQ.js} +11 -9
- package/dist/cli/{chunk-AVHLATII.js → chunk-VTF4RRWJ.js} +50 -50
- package/dist/cli/{chunk-LOGGNW4H.mjs → chunk-W3HMGKMI.mjs} +2 -2
- package/dist/cli/{chunk-JCN4DHF7.mjs → chunk-WM2QEHZL.mjs} +2 -2
- package/dist/cli/chunk-YHPYUZZX.mjs +112 -0
- package/dist/cli/chunk-YHZUZO3U.mjs +930 -0
- package/dist/cli/{chunk-ME6XRFLY.js → chunk-YLRME7MK.js} +15 -15
- package/dist/cli/{chunk-DC6LTULT.js → chunk-YSVORIEW.js} +2 -2
- package/dist/cli/{chunk-I4T4XAA2.mjs → chunk-YUDKBQUD.mjs} +4 -4
- package/dist/cli/chunk-ZAAKSJAS.js +88 -0
- package/dist/cli/{chunk-RMTASUAK.js → chunk-ZHUMDMOS.js} +65 -65
- package/dist/cli/chunk-ZM2YPJQJ.js +107 -0
- package/dist/cli/{csv-TF576S77.js → csv-AQBQ5O3I.js} +13 -12
- package/dist/cli/{csv-RLRR74RQ.mjs → csv-MB7PJMYQ.mjs} +4 -3
- package/dist/cli/{db-FDBJUTFO.js → db-JPUYC5RB.js} +30 -29
- package/dist/cli/{db-XORGNBIC.mjs → db-L5IEI2AU.mjs} +5 -4
- package/dist/cli/describe-6WT74AOR.js +164 -0
- package/dist/cli/describe-S6BFANVI.mjs +164 -0
- package/dist/cli/describe-core.d.mts +100 -0
- package/dist/cli/describe-core.d.ts +100 -0
- package/dist/cli/describe-core.js +18 -0
- package/dist/cli/describe-core.mjs +18 -0
- package/dist/cli/{executions-SFYAXPF4.js → executions-6TMQTFP4.js} +7 -6
- package/dist/cli/{executions-YPP7WR77.mjs → executions-L7I2ZW4Z.mjs} +5 -4
- package/dist/cli/{feedback-RBGA5ARU.mjs → feedback-DSJ63HK6.mjs} +4 -3
- package/dist/cli/{feedback-5UZFYMGB.js → feedback-XF7CQGMD.js} +8 -7
- package/dist/cli/{git-IRSAJEK2.mjs → git-C3ENM67D.mjs} +5 -4
- package/dist/cli/git-HYDZK2QR.js +24 -0
- package/dist/cli/index.js +93 -91
- package/dist/cli/index.mjs +35 -33
- package/dist/cli/{legacy-noops-CVAOQY2F.js → legacy-noops-B2NHWIVD.js} +8 -7
- package/dist/cli/{legacy-noops-NA7N6ZOU.mjs → legacy-noops-VFG2K6HK.mjs} +5 -4
- package/dist/cli/{monitors-4OMRXCXP.js → monitors-ORFWOVZB.js} +86 -85
- package/dist/cli/{monitors-ILZ2XHYG.mjs → monitors-TCEDBDGY.mjs} +5 -4
- package/dist/cli/{org-QDDXAE3J.mjs → org-45KREIKZ.mjs} +5 -4
- package/dist/cli/{org-YGNJDD2X.js → org-T74CJESN.js} +65 -64
- package/dist/cli/{play-VT6OHB2D.mjs → play-MU7MYBIM.mjs} +19 -15
- package/dist/cli/{play-L535H26U.js → play-XHK2LPON.js} +251 -247
- package/dist/cli/{providers-GPZ6PQAL.js → providers-4MGQKYFD.js} +8 -7
- package/dist/cli/{providers-KG4W5MPK.mjs → providers-VYCXIJT5.mjs} +5 -4
- package/dist/cli/{quickstart-UI27S5LO.js → quickstart-47G3VEOT.js} +6 -5
- package/dist/cli/{quickstart-2JDGTXIG.mjs → quickstart-H724EFM2.mjs} +4 -3
- package/dist/cli/search-3356ENLD.js +30 -0
- package/dist/cli/{search-PW3RAUX7.mjs → search-VQHXEFQ4.mjs} +7 -5
- package/dist/cli/{secrets-WFAXOUZE.js → secrets-ALLKCU35.js} +14 -13
- package/dist/cli/{secrets-HNOMK5A2.mjs → secrets-CPBNGA44.mjs} +5 -4
- package/dist/cli/{sessions-XLX3E5UO.mjs → sessions-7RSQB7IX.mjs} +5 -4
- package/dist/cli/sessions-FKGAY7WQ.js +16 -0
- package/dist/cli/{settings-YNZ4YKCH.mjs → settings-UYSGV4IC.mjs} +8 -7
- package/dist/cli/{settings-GADAG2UK.js → settings-Y5BI42P7.js} +75 -74
- package/dist/cli/{setup-PSEHIUXO.mjs → setup-L3ZBBTS4.mjs} +7 -6
- package/dist/cli/{setup-R5YO7GT6.js → setup-VXQPEU3E.js} +42 -41
- package/dist/cli/skills-DUZQTDTE.js +29 -0
- package/dist/cli/{skills-LTQBP6CZ.mjs → skills-QHVDLSFE.mjs} +5 -4
- package/dist/cli/{tools-UAXDWU63.mjs → tools-LSCEK4K2.mjs} +13 -8
- package/dist/cli/tools-YWU5QOQ5.js +39 -0
- package/dist/cli/update-5LYQAI55.js +29 -0
- package/dist/cli/{update-SMNIBIMS.mjs → update-CU22OTBM.mjs} +7 -6
- package/dist/cli/{workflow-AOQVZHMD.js → workflow-ERFLTRNX.js} +16 -15
- package/dist/cli/{workflow-IKGMBGF6.mjs → workflow-KQARK5BZ.mjs} +6 -5
- package/dist/{client-DiGl8ska.d.mts → client-D0j-_aaa.d.mts} +1 -1
- package/dist/{client-Bgis7F6-.d.ts → client-DflfVyj6.d.ts} +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +14 -10
- package/dist/index.mjs +19 -15
- package/dist/install-integrity.json +92 -76
- package/dist/plays/play-description.d.mts +1 -1
- package/dist/plays/play-description.d.ts +1 -1
- package/dist/plays/run-request.d.mts +1 -1
- package/dist/plays/run-request.d.ts +1 -1
- 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/package.json +6 -1
- package/dist/cli/auth-562JPKOM.js +0 -39
- package/dist/cli/git-5LDY5ZID.js +0 -23
- package/dist/cli/search-MGWROZ33.js +0 -28
- package/dist/cli/sessions-366KROUA.js +0 -15
- package/dist/cli/skills-JF2LPEGM.js +0 -28
- package/dist/cli/tools-CP2PEFRN.js +0 -34
- package/dist/cli/update-HZHZOU6C.js +0 -28
|
@@ -1,7 +1,7 @@
|
|
|
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
|
|
4
|
+
var _chunkUVXBVUZQjs = require('./chunk-UVXBVUZQ.js');
|
|
5
5
|
require('./chunk-S6R3OX7B.js');
|
|
6
6
|
require('./chunk-UHNDVD3P.js');
|
|
7
7
|
require('./chunk-KXMNM4AQ.js');
|
|
@@ -19,15 +19,16 @@ var _chunkIF75RD6Ujs = require('./chunk-IF75RD6U.js');
|
|
|
19
19
|
|
|
20
20
|
|
|
21
21
|
|
|
22
|
-
var
|
|
22
|
+
var _chunkDQ65ZVHNjs = require('./chunk-DQ65ZVHN.js');
|
|
23
|
+
require('./chunk-RYW4HPSM.js');
|
|
23
24
|
|
|
24
25
|
|
|
25
|
-
var
|
|
26
|
+
var _chunkQ2E4E4FJjs = require('./chunk-Q2E4E4FJ.js');
|
|
26
27
|
require('./chunk-XNYIZMNQ.js');
|
|
27
28
|
|
|
28
29
|
|
|
29
30
|
var _chunk7P5AA3SNjs = require('./chunk-7P5AA3SN.js');
|
|
30
|
-
require('./chunk-
|
|
31
|
+
require('./chunk-IZ74ABSX.js');
|
|
31
32
|
require('./chunk-OG64RBAC.js');
|
|
32
33
|
require('./chunk-COGTRVWW.js');
|
|
33
34
|
|
|
@@ -58,7 +59,7 @@ var MonitorDryRunUnsupportedError = (_class2 = class extends Error {
|
|
|
58
59
|
function monitorsErrorExitCode(error) {
|
|
59
60
|
if (error instanceof MonitorsUsageError) return 2;
|
|
60
61
|
if (error instanceof MonitorFleetStateError) return 6;
|
|
61
|
-
if (error instanceof
|
|
62
|
+
if (error instanceof _chunkQ2E4E4FJjs.AuthError) return 3;
|
|
62
63
|
if (error instanceof _chunk7P5AA3SNjs.DeeplineError) {
|
|
63
64
|
const status = error.statusCode;
|
|
64
65
|
if (status === 401 || status === 403) return 3;
|
|
@@ -105,10 +106,10 @@ function reportMonitorsFailure(error, options) {
|
|
|
105
106
|
const exitCode = monitorsErrorExitCode(error);
|
|
106
107
|
const next = monitorsFailureNextCommand(error, exitCode, options);
|
|
107
108
|
const retrySafe = exitCode === 5 && _optionalChain([options, 'optionalAccess', _9 => _9.retryCommand]) !== void 0;
|
|
108
|
-
const wantsJson =
|
|
109
|
+
const wantsJson = _chunkDQ65ZVHNjs.shouldEmitJson.call(void 0, process.argv.includes("--json"));
|
|
109
110
|
if (wantsJson) {
|
|
110
|
-
const payload =
|
|
111
|
-
|
|
111
|
+
const payload = _chunkDQ65ZVHNjs.errorToJsonPayload.call(void 0, error);
|
|
112
|
+
_chunkDQ65ZVHNjs.printJson.call(void 0, {
|
|
112
113
|
ok: false,
|
|
113
114
|
exitCode,
|
|
114
115
|
...next ? { next } : {},
|
|
@@ -522,14 +523,14 @@ Preview the plan first with:
|
|
|
522
523
|
);
|
|
523
524
|
}
|
|
524
525
|
async function handleMonitorsStatus(options) {
|
|
525
|
-
const payload = await new (0,
|
|
526
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.status();
|
|
526
527
|
const hasAccess = payload.has_access === true;
|
|
527
528
|
const reason = typeof payload.reason === "string" && payload.reason.trim() ? payload.reason.trim() : void 0;
|
|
528
529
|
const text = hasAccess ? `\u2713 You have access to Deepline Monitors${reason ? `
|
|
529
530
|
${reason}` : ""}
|
|
530
531
|
` : `\u2717 No access to Deepline Monitors${reason ? ` \u2014 ${reason}` : ""}
|
|
531
532
|
`;
|
|
532
|
-
|
|
533
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
533
534
|
{ has_access: hasAccess, ...reason ? { reason } : {} },
|
|
534
535
|
{ json: options.json, text }
|
|
535
536
|
);
|
|
@@ -595,14 +596,14 @@ async function handleMonitorsAvailable(toolId, options) {
|
|
|
595
596
|
}
|
|
596
597
|
}
|
|
597
598
|
const tool = _nullishCoalesce(toolId, () => ( options.tool));
|
|
598
|
-
const payload = await new (0,
|
|
599
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.available(tool, {
|
|
599
600
|
...options.provider ? { provider: options.provider } : {},
|
|
600
601
|
...options.search ? { search: options.search } : {},
|
|
601
602
|
...options.limit ? { limit: options.limit } : {},
|
|
602
603
|
...options.full ? { full: true } : {},
|
|
603
604
|
...options.compact ? { compact: true } : {}
|
|
604
605
|
});
|
|
605
|
-
|
|
606
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
606
607
|
json: options.json,
|
|
607
608
|
// Human list view shows id + name + deployed_count ("deployed: N") so
|
|
608
609
|
// can-deploy vs already-deployed is visible in one view. Describing a
|
|
@@ -705,14 +706,14 @@ async function handleMonitorsList(options) {
|
|
|
705
706
|
"`--compact` is deprecated and now does nothing; returning the complete monitor records.\n"
|
|
706
707
|
);
|
|
707
708
|
}
|
|
708
|
-
const payload = await new (0,
|
|
709
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.list({
|
|
709
710
|
...state ? { state } : {},
|
|
710
711
|
...options.status ? { status: options.status } : {},
|
|
711
712
|
...options.limit ? { limit: options.limit } : {},
|
|
712
713
|
...options.cursor ? { cursor: options.cursor } : {},
|
|
713
714
|
...options.includeConsumers ? { includeConsumers: true } : {}
|
|
714
715
|
});
|
|
715
|
-
|
|
716
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
716
717
|
json: options.json,
|
|
717
718
|
text: renderDeployedListText(
|
|
718
719
|
payload,
|
|
@@ -728,10 +729,10 @@ async function handleMonitorsCheck(definition, options) {
|
|
|
728
729
|
argLabel: "<definition>",
|
|
729
730
|
command: "deepline monitors check"
|
|
730
731
|
});
|
|
731
|
-
const payload = await new (0,
|
|
732
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.check(
|
|
732
733
|
body
|
|
733
734
|
);
|
|
734
|
-
|
|
735
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
735
736
|
}
|
|
736
737
|
async function handleMonitorsDeploy(definition, options) {
|
|
737
738
|
const body = resolveMonitorJsonBody({
|
|
@@ -740,7 +741,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
740
741
|
argLabel: "<definition>",
|
|
741
742
|
command: "deepline monitors deploy"
|
|
742
743
|
});
|
|
743
|
-
const client = new (0,
|
|
744
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
744
745
|
const definitionArg = body;
|
|
745
746
|
if (options.dryRun) {
|
|
746
747
|
const payload2 = await client.monitors.deploy(definitionArg, {
|
|
@@ -748,7 +749,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
748
749
|
});
|
|
749
750
|
const valid = payload2.valid !== false;
|
|
750
751
|
const hasIdentityConflict = Boolean(_optionalChain([asRecord, 'call', _21 => _21(payload2), 'optionalAccess', _22 => _22.identity_conflict]));
|
|
751
|
-
|
|
752
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
752
753
|
{ dry_run: true, ...payload2 },
|
|
753
754
|
{ json: options.json, text: renderMonitorDeployPlan(payload2) }
|
|
754
755
|
);
|
|
@@ -758,7 +759,7 @@ async function handleMonitorsDeploy(definition, options) {
|
|
|
758
759
|
return;
|
|
759
760
|
}
|
|
760
761
|
const payload = await client.monitors.deploy(definitionArg);
|
|
761
|
-
|
|
762
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
762
763
|
json: options.json,
|
|
763
764
|
text: renderMonitorDeployCompletion(payload)
|
|
764
765
|
});
|
|
@@ -770,29 +771,29 @@ async function handleMonitorsSync(definition, options) {
|
|
|
770
771
|
argLabel: "<definition>",
|
|
771
772
|
command: "deepline monitors sync"
|
|
772
773
|
});
|
|
773
|
-
const payload = await new (0,
|
|
774
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.sync(body, {
|
|
774
775
|
...options.dryRun ? { dryRun: true } : {},
|
|
775
776
|
idempotencyKey: _nullishCoalesce(options.idempotencyKey, () => ( monitorJobIdempotencyKey("scalar-sync", void 0)))
|
|
776
777
|
});
|
|
777
778
|
if (options.dryRun) {
|
|
778
779
|
const plan = payload;
|
|
779
|
-
|
|
780
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
780
781
|
{ dry_run: true, ...plan },
|
|
781
782
|
{ json: options.json, text: renderMonitorDeployPlan(plan) }
|
|
782
783
|
);
|
|
783
784
|
return;
|
|
784
785
|
}
|
|
785
|
-
|
|
786
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
786
787
|
json: options.json,
|
|
787
788
|
text: renderMonitorJob(payload)
|
|
788
789
|
});
|
|
789
790
|
}
|
|
790
791
|
async function handleScalarMonitorLifecycle(action, key, options) {
|
|
791
|
-
const payload = await new (0,
|
|
792
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors[action](key, {
|
|
792
793
|
...options.dryRun ? { dryRun: true } : {},
|
|
793
794
|
idempotencyKey: _nullishCoalesce(options.idempotencyKey, () => ( monitorJobIdempotencyKey(`${action}-${key}`, void 0)))
|
|
794
795
|
});
|
|
795
|
-
|
|
796
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
796
797
|
json: options.json,
|
|
797
798
|
text: options.dryRun ? void 0 : renderMonitorJob(payload)
|
|
798
799
|
});
|
|
@@ -881,11 +882,11 @@ async function handleMonitorJobBatchDeploy(options, idempotencyKey) {
|
|
|
881
882
|
lint.issues.filter((issue) => issue.severity === "error").map((issue) => `${issue.path || "batch"}: ${issue.message}`).join("; ")
|
|
882
883
|
);
|
|
883
884
|
}
|
|
884
|
-
const payload = await new (0,
|
|
885
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batch.deploy(
|
|
885
886
|
lint.normalized.monitors,
|
|
886
887
|
{ idempotencyKey }
|
|
887
888
|
);
|
|
888
|
-
|
|
889
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
889
890
|
{
|
|
890
891
|
...payload,
|
|
891
892
|
idempotency_key: idempotencyKey,
|
|
@@ -918,7 +919,7 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
918
919
|
);
|
|
919
920
|
}
|
|
920
921
|
if (options.dryRun) {
|
|
921
|
-
|
|
922
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
922
923
|
{
|
|
923
924
|
ok: true,
|
|
924
925
|
dry_run: true,
|
|
@@ -935,7 +936,7 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
935
936
|
"sync",
|
|
936
937
|
options.idempotencyKey
|
|
937
938
|
);
|
|
938
|
-
const payload = await new (0,
|
|
939
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batches.sync(
|
|
939
940
|
batchId,
|
|
940
941
|
lint.normalized.monitors,
|
|
941
942
|
{
|
|
@@ -943,14 +944,14 @@ async function handleNamedMonitorBatchSync(batchId, options) {
|
|
|
943
944
|
...parsedGeneration === void 0 ? {} : { expectedGeneration: parsedGeneration }
|
|
944
945
|
}
|
|
945
946
|
);
|
|
946
|
-
|
|
947
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
947
948
|
{ ...payload, idempotency_key: idempotencyKey },
|
|
948
949
|
{ json: options.json, text: renderMonitorJob(payload) }
|
|
949
950
|
);
|
|
950
951
|
}
|
|
951
952
|
async function handleNamedMonitorBatchLifecycle(batchId, intent, options) {
|
|
952
953
|
if (options.dryRun) {
|
|
953
|
-
|
|
954
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
954
955
|
{
|
|
955
956
|
ok: true,
|
|
956
957
|
dry_run: true,
|
|
@@ -966,17 +967,17 @@ async function handleNamedMonitorBatchLifecycle(batchId, intent, options) {
|
|
|
966
967
|
intent,
|
|
967
968
|
options.idempotencyKey
|
|
968
969
|
);
|
|
969
|
-
const payload = await new (0,
|
|
970
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batches[intent](batchId, {
|
|
970
971
|
idempotencyKey
|
|
971
972
|
});
|
|
972
|
-
|
|
973
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
973
974
|
{ ...payload, idempotency_key: idempotencyKey },
|
|
974
975
|
{ json: options.json, text: renderMonitorJob(payload) }
|
|
975
976
|
);
|
|
976
977
|
}
|
|
977
978
|
async function handleNamedMonitorBatchGet(batchId, options) {
|
|
978
|
-
const payload = await new (0,
|
|
979
|
-
|
|
979
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batches.get(batchId);
|
|
980
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
980
981
|
json: options.json,
|
|
981
982
|
text: renderMonitorJob(payload)
|
|
982
983
|
});
|
|
@@ -990,7 +991,7 @@ async function handleMonitorBatchLint(options) {
|
|
|
990
991
|
const result = _chunkIF75RD6Ujs.lintMonitorBatchInput.call(void 0,
|
|
991
992
|
readMonitorDefinitionsJsonFile(options.file)
|
|
992
993
|
);
|
|
993
|
-
|
|
994
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
994
995
|
{
|
|
995
996
|
ok: !result.issues.some((issue) => issue.severity === "error"),
|
|
996
997
|
...result.normalized ? { normalized: result.normalized } : {},
|
|
@@ -1010,7 +1011,7 @@ async function handleMonitorFleetLint(options) {
|
|
|
1010
1011
|
const result = _chunkC374C22Yjs.lintMonitorFleetInput.call(void 0,
|
|
1011
1012
|
readMonitorDefinitionsJsonFile(options.file)
|
|
1012
1013
|
);
|
|
1013
|
-
|
|
1014
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
1014
1015
|
{
|
|
1015
1016
|
ok: !result.issues.some((issue) => issue.severity === "error"),
|
|
1016
1017
|
...result.normalized ? { normalized: result.normalized } : {},
|
|
@@ -1022,32 +1023,32 @@ async function handleMonitorFleetLint(options) {
|
|
|
1022
1023
|
process.exitCode = 2;
|
|
1023
1024
|
}
|
|
1024
1025
|
async function handleMonitorJobGet(jobId, options) {
|
|
1025
|
-
const payload = await new (0,
|
|
1026
|
-
|
|
1026
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.jobs.get(jobId);
|
|
1027
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
1027
1028
|
json: options.json,
|
|
1028
1029
|
text: renderMonitorJob(payload)
|
|
1029
1030
|
});
|
|
1030
1031
|
}
|
|
1031
1032
|
async function handleMonitorJobWait(jobId, options) {
|
|
1032
|
-
const payload = await new (0,
|
|
1033
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.jobs.wait(jobId, {
|
|
1033
1034
|
timeoutMs: fleetTimeoutMs(options.timeout),
|
|
1034
1035
|
pollIntervalMs: FLEET_POLL_INTERVAL_MS
|
|
1035
1036
|
});
|
|
1036
|
-
|
|
1037
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
1037
1038
|
json: options.json,
|
|
1038
1039
|
text: renderMonitorJob(payload)
|
|
1039
1040
|
});
|
|
1040
1041
|
}
|
|
1041
1042
|
async function handleMonitorJobLogs(jobId, options) {
|
|
1042
1043
|
const limit = options.limit ? fleetIntegerOption(options.limit, "--limit") : void 0;
|
|
1043
|
-
const payload = await new (0,
|
|
1044
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.jobs.logs(jobId, {
|
|
1044
1045
|
...limit === void 0 ? {} : { limit }
|
|
1045
1046
|
});
|
|
1046
|
-
|
|
1047
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
1047
1048
|
}
|
|
1048
1049
|
async function handleMonitorJobCancel(jobId, options) {
|
|
1049
|
-
const payload = await new (0,
|
|
1050
|
-
|
|
1050
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.jobs.cancel(jobId);
|
|
1051
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, {
|
|
1051
1052
|
json: options.json,
|
|
1052
1053
|
text: renderMonitorJob(payload)
|
|
1053
1054
|
});
|
|
@@ -1345,7 +1346,7 @@ function renderFleetDeactivatePlan(payload, fleetId) {
|
|
|
1345
1346
|
`;
|
|
1346
1347
|
}
|
|
1347
1348
|
function reportFleetState(payload, error, options) {
|
|
1348
|
-
|
|
1349
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
1349
1350
|
{
|
|
1350
1351
|
...payload,
|
|
1351
1352
|
code: error.code,
|
|
@@ -1460,7 +1461,7 @@ async function handleMonitorFleetsInit(fleetId, options) {
|
|
|
1460
1461
|
_fs.writeFileSync.call(void 0, file, `${JSON.stringify(definition, null, 2)}
|
|
1461
1462
|
`, "utf8");
|
|
1462
1463
|
const next = `deepline monitors fleets deploy --file ${fleetShellArg(file)} --dry-run`;
|
|
1463
|
-
|
|
1464
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
1464
1465
|
{ schemaVersion: 2, file, definition, next },
|
|
1465
1466
|
{
|
|
1466
1467
|
json: options.json,
|
|
@@ -1522,7 +1523,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1522
1523
|
'The Fleet definition has no id. Add a top-level "id" and re-run.'
|
|
1523
1524
|
);
|
|
1524
1525
|
}
|
|
1525
|
-
const client = new (0,
|
|
1526
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
1526
1527
|
const payload = await client.monitors.fleets.sync(
|
|
1527
1528
|
_nullishCoalesce(definition, () => ( fleetId)),
|
|
1528
1529
|
{
|
|
@@ -1544,7 +1545,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1544
1545
|
}
|
|
1545
1546
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1546
1547
|
if (!options.wait || options.dryRun) {
|
|
1547
|
-
|
|
1548
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1548
1549
|
json: options.json,
|
|
1549
1550
|
text: renderFleetSync(payload, {
|
|
1550
1551
|
fleetId,
|
|
@@ -1570,7 +1571,7 @@ async function handleMonitorFleetsSync(target, options, idempotencyKey) {
|
|
|
1570
1571
|
const status = fleetStatus(final);
|
|
1571
1572
|
const summary = renderFleetGet(final);
|
|
1572
1573
|
if (status === "converged") {
|
|
1573
|
-
|
|
1574
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text: summary });
|
|
1574
1575
|
return;
|
|
1575
1576
|
}
|
|
1576
1577
|
const driftCommand = `deepline monitors fleets get ${fleetShellArg(fleetId)} --drift`;
|
|
@@ -1603,14 +1604,14 @@ async function handleMonitorFleetsGet(fleetId, options) {
|
|
|
1603
1604
|
);
|
|
1604
1605
|
}
|
|
1605
1606
|
const limit = options.limit === void 0 ? void 0 : fleetIntegerOption(options.limit, "--limit");
|
|
1606
|
-
const client = new (0,
|
|
1607
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
1607
1608
|
const payload = await client.monitors.fleets.get(fleetId, {
|
|
1608
1609
|
...options.drift ? { drift: true } : {},
|
|
1609
1610
|
...limit !== void 0 ? { limit } : {}
|
|
1610
1611
|
});
|
|
1611
1612
|
const text = fleetId ? renderFleetGet(payload) : renderFleetList(payload);
|
|
1612
1613
|
if (!options.check) {
|
|
1613
|
-
|
|
1614
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json, text });
|
|
1614
1615
|
return;
|
|
1615
1616
|
}
|
|
1616
1617
|
const statuses = fleetId ? [fleetStatus(payload)] : (Array.isArray(payload.fleets) ? payload.fleets : []).map(
|
|
@@ -1618,7 +1619,7 @@ async function handleMonitorFleetsGet(fleetId, options) {
|
|
|
1618
1619
|
);
|
|
1619
1620
|
const unconverged = statuses.filter((status) => status !== "converged");
|
|
1620
1621
|
if (unconverged.length === 0) {
|
|
1621
|
-
|
|
1622
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json, text });
|
|
1622
1623
|
return;
|
|
1623
1624
|
}
|
|
1624
1625
|
const target = _nullishCoalesce(fleetId, () => ( "<fleet-id>"));
|
|
@@ -1657,13 +1658,13 @@ async function handleMonitorFleetsReactivate(fleetId, options, idempotencyKey) {
|
|
|
1657
1658
|
${fleetReactivateCommandLine(fleetId, options)}`
|
|
1658
1659
|
);
|
|
1659
1660
|
}
|
|
1660
|
-
const client = new (0,
|
|
1661
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
1661
1662
|
const payload = await client.monitors.fleets.reactivate(fleetId, {
|
|
1662
1663
|
idempotencyKey
|
|
1663
1664
|
});
|
|
1664
1665
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1665
1666
|
if (!options.wait) {
|
|
1666
|
-
|
|
1667
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1667
1668
|
json: options.json,
|
|
1668
1669
|
text: `Fleet ${fleetId} \u2014 ${readMonitorState(payload) ? `state ${readMonitorState(payload)}` : "reactivation accepted"}
|
|
1669
1670
|
idempotency key ${idempotencyKey}
|
|
@@ -1686,7 +1687,7 @@ async function handleMonitorFleetsReactivate(fleetId, options, idempotencyKey) {
|
|
|
1686
1687
|
const envelope = { ...accepted, ...final };
|
|
1687
1688
|
const text = renderFleetGet(final);
|
|
1688
1689
|
if (fleetStatus(final) === "converged") {
|
|
1689
|
-
|
|
1690
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text });
|
|
1690
1691
|
return;
|
|
1691
1692
|
}
|
|
1692
1693
|
reportFleetState(
|
|
@@ -1728,7 +1729,7 @@ async function confirmFleetDeactivate(fleetId, plan) {
|
|
|
1728
1729
|
}
|
|
1729
1730
|
}
|
|
1730
1731
|
async function handleMonitorFleetsDeactivate(fleetId, options, idempotencyKey) {
|
|
1731
|
-
const client = new (0,
|
|
1732
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
1732
1733
|
if (options.dryRun) {
|
|
1733
1734
|
const plan = await client.monitors.fleets.deactivate(fleetId, {
|
|
1734
1735
|
dryRun: true,
|
|
@@ -1738,7 +1739,7 @@ async function handleMonitorFleetsDeactivate(fleetId, options, idempotencyKey) {
|
|
|
1738
1739
|
command: "deepline monitors fleets deactivate",
|
|
1739
1740
|
mutation: "fleet deactivate"
|
|
1740
1741
|
});
|
|
1741
|
-
|
|
1742
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, plan, {
|
|
1742
1743
|
json: options.json,
|
|
1743
1744
|
text: renderFleetDeactivatePlan(plan, fleetId)
|
|
1744
1745
|
});
|
|
@@ -1776,7 +1777,7 @@ Preview the blast radius first:
|
|
|
1776
1777
|
});
|
|
1777
1778
|
const accepted = { ...payload, idempotency_key: idempotencyKey };
|
|
1778
1779
|
if (payload.already === true) {
|
|
1779
|
-
|
|
1780
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1780
1781
|
json: options.json,
|
|
1781
1782
|
text: `Fleet ${fleetId} is already deactivated.
|
|
1782
1783
|
`
|
|
@@ -1788,7 +1789,7 @@ Preview the blast radius first:
|
|
|
1788
1789
|
` + (fleetServerNext(payload) ? `Next: ${fleetServerNext(payload)}
|
|
1789
1790
|
` : "");
|
|
1790
1791
|
if (!options.wait) {
|
|
1791
|
-
|
|
1792
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, accepted, {
|
|
1792
1793
|
json: options.json,
|
|
1793
1794
|
text: acceptedText
|
|
1794
1795
|
});
|
|
@@ -1810,7 +1811,7 @@ Preview the blast radius first:
|
|
|
1810
1811
|
const envelope = { ...accepted, ...final };
|
|
1811
1812
|
const summary = renderFleetGet(final);
|
|
1812
1813
|
if (fleetStatus(final) === "deactivated") {
|
|
1813
|
-
|
|
1814
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, envelope, { json: options.json, text: summary });
|
|
1814
1815
|
return;
|
|
1815
1816
|
}
|
|
1816
1817
|
reportFleetState(
|
|
@@ -1841,7 +1842,7 @@ function handleMonitorFleetsOverview(options) {
|
|
|
1841
1842
|
"Agent notes:",
|
|
1842
1843
|
...MONITOR_FLEET_AGENT_NOTES.map((note) => ` ${note}`)
|
|
1843
1844
|
];
|
|
1844
|
-
|
|
1845
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
1845
1846
|
{
|
|
1846
1847
|
schemaVersion: 1,
|
|
1847
1848
|
lifecycle: MONITOR_FLEET_LIFECYCLE,
|
|
@@ -2002,7 +2003,7 @@ function renderMonitorGet(payload) {
|
|
|
2002
2003
|
`;
|
|
2003
2004
|
}
|
|
2004
2005
|
async function handleMonitorsGet(key, options) {
|
|
2005
|
-
const client = new (0,
|
|
2006
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
2006
2007
|
const payload = await client.monitors.get(key);
|
|
2007
2008
|
const boundPlays = Array.isArray(payload.bound_plays) ? payload.bound_plays : null;
|
|
2008
2009
|
const dependents = boundPlays ? {
|
|
@@ -2010,24 +2011,24 @@ async function handleMonitorsGet(key, options) {
|
|
|
2010
2011
|
truncated: payload.consumer_health_truncated === true
|
|
2011
2012
|
} : await client.monitors.dependents(key);
|
|
2012
2013
|
const detail = { ...payload, dependents };
|
|
2013
|
-
|
|
2014
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, detail, {
|
|
2014
2015
|
json: options.json,
|
|
2015
2016
|
text: renderMonitorGet(detail)
|
|
2016
2017
|
});
|
|
2017
2018
|
}
|
|
2018
2019
|
async function handleMonitorsTest(key, payload, options) {
|
|
2019
2020
|
const explicitPayload = parseJsonObjectArg(payload, "<payload>");
|
|
2020
|
-
const result = await new (0,
|
|
2021
|
+
const result = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.test(key, explicitPayload);
|
|
2021
2022
|
const text = `Monitor diagnostic for ${key}: ${result.accepted === true ? "accepted" : "rejected"}
|
|
2022
2023
|
mode: validation_only (no rows written, credits spent, or Plays dispatched)
|
|
2023
2024
|
persisted rows: ${_nullishCoalesce(asFiniteNumber(result.persisted_rows), () => ( 0))}
|
|
2024
2025
|
dispatched bound Plays: ${_nullishCoalesce(asFiniteNumber(result.dispatched_bound_plays), () => ( 0))}
|
|
2025
2026
|
`;
|
|
2026
|
-
|
|
2027
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, result, { json: options.json, text });
|
|
2027
2028
|
}
|
|
2028
2029
|
async function handleMonitorsValidate(key, options) {
|
|
2029
|
-
const result = await new (0,
|
|
2030
|
-
|
|
2030
|
+
const result = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.validate(key);
|
|
2031
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, result, { json: options.json });
|
|
2031
2032
|
if (result.valid === false) process.exitCode = 7;
|
|
2032
2033
|
}
|
|
2033
2034
|
async function confirmMonitorDelete(key) {
|
|
@@ -2045,14 +2046,14 @@ async function confirmMonitorDelete(key) {
|
|
|
2045
2046
|
}
|
|
2046
2047
|
}
|
|
2047
2048
|
async function handleMonitorsDelete(key, options) {
|
|
2048
|
-
const client = new (0,
|
|
2049
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
2049
2050
|
if (options.dryRun) {
|
|
2050
2051
|
const payload2 = await client.monitors.delete(key, { dryRun: true });
|
|
2051
2052
|
assertMonitorDryRunAcknowledged(payload2, {
|
|
2052
2053
|
command: "deepline monitors delete",
|
|
2053
2054
|
mutation: "delete"
|
|
2054
2055
|
});
|
|
2055
|
-
|
|
2056
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload2, {
|
|
2056
2057
|
json: options.json,
|
|
2057
2058
|
text: renderMonitorDeletePlan(payload2, key)
|
|
2058
2059
|
});
|
|
@@ -2072,7 +2073,7 @@ async function handleMonitorsDelete(key, options) {
|
|
|
2072
2073
|
}
|
|
2073
2074
|
}
|
|
2074
2075
|
const payload = await client.monitors.delete(key);
|
|
2075
|
-
|
|
2076
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2076
2077
|
}
|
|
2077
2078
|
async function handleMonitorsUpdate(key, patch, options) {
|
|
2078
2079
|
const body = resolveMonitorJsonBody({
|
|
@@ -2081,25 +2082,25 @@ async function handleMonitorsUpdate(key, patch, options) {
|
|
|
2081
2082
|
argLabel: "<patch>",
|
|
2082
2083
|
command: `deepline monitors update ${key}`
|
|
2083
2084
|
});
|
|
2084
|
-
const payload = await new (0,
|
|
2085
|
-
|
|
2085
|
+
const payload = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.update(key, body);
|
|
2086
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2086
2087
|
}
|
|
2087
2088
|
async function handleMonitorsReactivate(key, options) {
|
|
2088
|
-
const client = new (0,
|
|
2089
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
2089
2090
|
if (options.dryRun) {
|
|
2090
2091
|
const payload2 = await client.monitors.reactivate(key, { dryRun: true });
|
|
2091
2092
|
assertMonitorDryRunAcknowledged(payload2, {
|
|
2092
2093
|
command: "deepline monitors reactivate",
|
|
2093
2094
|
mutation: "reactivate"
|
|
2094
2095
|
});
|
|
2095
|
-
|
|
2096
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload2, {
|
|
2096
2097
|
json: options.json,
|
|
2097
2098
|
text: renderMonitorReactivatePlan(payload2, key)
|
|
2098
2099
|
});
|
|
2099
2100
|
return;
|
|
2100
2101
|
}
|
|
2101
2102
|
const payload = await client.monitors.reactivate(key);
|
|
2102
|
-
|
|
2103
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, payload, { json: options.json });
|
|
2103
2104
|
}
|
|
2104
2105
|
var MONITOR_VERB_POLL_INTERVAL_MS = 2e3;
|
|
2105
2106
|
function monitorHealthLine(health) {
|
|
@@ -2221,7 +2222,7 @@ function monitorHealthText(health) {
|
|
|
2221
2222
|
`;
|
|
2222
2223
|
}
|
|
2223
2224
|
async function handleMonitorsAudit(options) {
|
|
2224
|
-
const client = new (0,
|
|
2225
|
+
const client = new (0, _chunkUVXBVUZQjs.DeeplineClient)();
|
|
2225
2226
|
const fleetId = _optionalChain([options, 'access', _73 => _73.fleet, 'optionalAccess', _74 => _74.trim, 'call', _75 => _75()]) || void 0;
|
|
2226
2227
|
const scope = fleetId ? { fleetId } : {};
|
|
2227
2228
|
let result = await client.monitors.audit(scope);
|
|
@@ -2265,7 +2266,7 @@ async function handleMonitorsAudit(options) {
|
|
|
2265
2266
|
"",
|
|
2266
2267
|
monitorHealthText(health)
|
|
2267
2268
|
].join("\n");
|
|
2268
|
-
|
|
2269
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
2269
2270
|
{ ...result, audit: { ...result.audit, totals }, health },
|
|
2270
2271
|
{ json: options.json, text }
|
|
2271
2272
|
);
|
|
@@ -2278,10 +2279,10 @@ async function handleMonitorsRepair(options) {
|
|
|
2278
2279
|
}
|
|
2279
2280
|
async function handleMonitorsHealth(options) {
|
|
2280
2281
|
const fleetId = _optionalChain([options, 'access', _79 => _79.fleet, 'optionalAccess', _80 => _80.trim, 'call', _81 => _81()]) || void 0;
|
|
2281
|
-
const health = await new (0,
|
|
2282
|
+
const health = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.health(
|
|
2282
2283
|
fleetId ? { fleetId } : {}
|
|
2283
2284
|
);
|
|
2284
|
-
|
|
2285
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, health, {
|
|
2285
2286
|
json: options.json,
|
|
2286
2287
|
text: monitorHealthText(health)
|
|
2287
2288
|
});
|
|
@@ -2355,14 +2356,14 @@ async function handleMonitorBatchDeploy(options) {
|
|
|
2355
2356
|
"deploy",
|
|
2356
2357
|
options.idempotencyKey
|
|
2357
2358
|
);
|
|
2358
|
-
const result = await new (0,
|
|
2359
|
+
const result = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batch.submit({
|
|
2359
2360
|
kind: "deploy",
|
|
2360
2361
|
manifestNdjson,
|
|
2361
2362
|
dryRun: options.dryRun === true,
|
|
2362
2363
|
idempotencyKey
|
|
2363
2364
|
});
|
|
2364
2365
|
const operation = result.operation;
|
|
2365
|
-
|
|
2366
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
2366
2367
|
{ ...result, idempotency_key: idempotencyKey },
|
|
2367
2368
|
{
|
|
2368
2369
|
json: options.json,
|
|
@@ -2390,7 +2391,7 @@ async function handleMonitorBatch(kind, options) {
|
|
|
2390
2391
|
kind,
|
|
2391
2392
|
options.idempotencyKey
|
|
2392
2393
|
);
|
|
2393
|
-
const result = await new (0,
|
|
2394
|
+
const result = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batch.submit({
|
|
2394
2395
|
kind,
|
|
2395
2396
|
scope,
|
|
2396
2397
|
dryRun: options.dryRun === true,
|
|
@@ -2403,14 +2404,14 @@ async function handleMonitorBatch(kind, options) {
|
|
|
2403
2404
|
`state ${operation.state} \xB7 retry key ${idempotencyKey}`,
|
|
2404
2405
|
`inspect: deepline monitors batch get ${operation.runId}`
|
|
2405
2406
|
].join("\n");
|
|
2406
|
-
|
|
2407
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0,
|
|
2407
2408
|
{ ...result, idempotency_key: idempotencyKey },
|
|
2408
2409
|
{ json: options.json, text: `${text}
|
|
2409
2410
|
` }
|
|
2410
2411
|
);
|
|
2411
2412
|
}
|
|
2412
2413
|
async function handleMonitorBatchGet(operationId, options) {
|
|
2413
|
-
const result = await new (0,
|
|
2414
|
+
const result = await new (0, _chunkUVXBVUZQjs.DeeplineClient)().monitors.batch.get(operationId, {
|
|
2414
2415
|
...options.cursor ? { cursor: options.cursor } : {}
|
|
2415
2416
|
});
|
|
2416
2417
|
const summary = _nullishCoalesce(result.operation.summary, () => ( {}));
|
|
@@ -2422,7 +2423,7 @@ async function handleMonitorBatchGet(operationId, options) {
|
|
|
2422
2423
|
`results ${result.results.page.length}${result.results.isDone ? "" : " (more; pass --cursor)"}`
|
|
2423
2424
|
] : []
|
|
2424
2425
|
].join("\n");
|
|
2425
|
-
|
|
2426
|
+
_chunkDQ65ZVHNjs.printCommandEnvelope.call(void 0, result, { json: options.json, text: `${text}
|
|
2426
2427
|
` });
|
|
2427
2428
|
}
|
|
2428
2429
|
function registerMonitorsCommands(program) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./chunk-EXMLR72R.mjs";
|
|
2
2
|
import {
|
|
3
3
|
DeeplineClient
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-J7ABTQQ7.mjs";
|
|
5
5
|
import "./chunk-6IKARAYD.mjs";
|
|
6
6
|
import "./chunk-JI2B4RZP.mjs";
|
|
7
7
|
import "./chunk-EIMG75BT.mjs";
|
|
@@ -19,15 +19,16 @@ import {
|
|
|
19
19
|
printCommandEnvelope,
|
|
20
20
|
printJson,
|
|
21
21
|
shouldEmitJson
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-RNSWDKBM.mjs";
|
|
23
|
+
import "./chunk-2LDADJNO.mjs";
|
|
23
24
|
import {
|
|
24
25
|
AuthError
|
|
25
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-YHPYUZZX.mjs";
|
|
26
27
|
import "./chunk-DLIRSHV6.mjs";
|
|
27
28
|
import {
|
|
28
29
|
DeeplineError
|
|
29
30
|
} from "./chunk-NXGCO4JB.mjs";
|
|
30
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-MRXMMERY.mjs";
|
|
31
32
|
import "./chunk-WZYKRD7T.mjs";
|
|
32
33
|
import "./chunk-KRD6H754.mjs";
|
|
33
34
|
|