@localstack/appinspector-ui 1.0.197 → 1.0.199
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/index.cjs +518 -347
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +510 -339
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -495,7 +495,7 @@ var require_parse = __commonJS({
|
|
|
495
495
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/parse.js"(exports, module) {
|
|
496
496
|
"use strict";
|
|
497
497
|
var SemVer = require_semver();
|
|
498
|
-
var
|
|
498
|
+
var parse3 = (version, options, throwErrors = false) => {
|
|
499
499
|
if (version instanceof SemVer) {
|
|
500
500
|
return version;
|
|
501
501
|
}
|
|
@@ -508,7 +508,7 @@ var require_parse = __commonJS({
|
|
|
508
508
|
throw er;
|
|
509
509
|
}
|
|
510
510
|
};
|
|
511
|
-
module.exports =
|
|
511
|
+
module.exports = parse3;
|
|
512
512
|
}
|
|
513
513
|
});
|
|
514
514
|
|
|
@@ -516,9 +516,9 @@ var require_parse = __commonJS({
|
|
|
516
516
|
var require_valid = __commonJS({
|
|
517
517
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/valid.js"(exports, module) {
|
|
518
518
|
"use strict";
|
|
519
|
-
var
|
|
519
|
+
var parse3 = require_parse();
|
|
520
520
|
var valid = (version, options) => {
|
|
521
|
-
const v =
|
|
521
|
+
const v = parse3(version, options);
|
|
522
522
|
return v ? v.version : null;
|
|
523
523
|
};
|
|
524
524
|
module.exports = valid;
|
|
@@ -529,9 +529,9 @@ var require_valid = __commonJS({
|
|
|
529
529
|
var require_clean = __commonJS({
|
|
530
530
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/clean.js"(exports, module) {
|
|
531
531
|
"use strict";
|
|
532
|
-
var
|
|
532
|
+
var parse3 = require_parse();
|
|
533
533
|
var clean = (version, options) => {
|
|
534
|
-
const s =
|
|
534
|
+
const s = parse3(version.trim().replace(/^[=v]+/, ""), options);
|
|
535
535
|
return s ? s.version : null;
|
|
536
536
|
};
|
|
537
537
|
module.exports = clean;
|
|
@@ -566,10 +566,10 @@ var require_inc = __commonJS({
|
|
|
566
566
|
var require_diff = __commonJS({
|
|
567
567
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/diff.js"(exports, module) {
|
|
568
568
|
"use strict";
|
|
569
|
-
var
|
|
569
|
+
var parse3 = require_parse();
|
|
570
570
|
var diff = (version1, version2) => {
|
|
571
|
-
const v1 =
|
|
572
|
-
const v2 =
|
|
571
|
+
const v1 = parse3(version1, null, true);
|
|
572
|
+
const v2 = parse3(version2, null, true);
|
|
573
573
|
const comparison = v1.compare(v2);
|
|
574
574
|
if (comparison === 0) {
|
|
575
575
|
return null;
|
|
@@ -640,9 +640,9 @@ var require_patch = __commonJS({
|
|
|
640
640
|
var require_prerelease = __commonJS({
|
|
641
641
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/prerelease.js"(exports, module) {
|
|
642
642
|
"use strict";
|
|
643
|
-
var
|
|
643
|
+
var parse3 = require_parse();
|
|
644
644
|
var prerelease = (version, options) => {
|
|
645
|
-
const parsed =
|
|
645
|
+
const parsed = parse3(version, options);
|
|
646
646
|
return parsed && parsed.prerelease.length ? parsed.prerelease : null;
|
|
647
647
|
};
|
|
648
648
|
module.exports = prerelease;
|
|
@@ -828,7 +828,7 @@ var require_coerce = __commonJS({
|
|
|
828
828
|
"node_modules/.pnpm/semver@7.7.4/node_modules/semver/functions/coerce.js"(exports, module) {
|
|
829
829
|
"use strict";
|
|
830
830
|
var SemVer = require_semver();
|
|
831
|
-
var
|
|
831
|
+
var parse3 = require_parse();
|
|
832
832
|
var { safeRe: re, t } = require_re();
|
|
833
833
|
var coerce = (version, options) => {
|
|
834
834
|
if (version instanceof SemVer) {
|
|
@@ -863,7 +863,7 @@ var require_coerce = __commonJS({
|
|
|
863
863
|
const patch = match[4] || "0";
|
|
864
864
|
const prerelease = options.includePrerelease && match[5] ? `-${match[5]}` : "";
|
|
865
865
|
const build = options.includePrerelease && match[6] ? `+${match[6]}` : "";
|
|
866
|
-
return
|
|
866
|
+
return parse3(`${major}.${minor}.${patch}${prerelease}${build}`, options);
|
|
867
867
|
};
|
|
868
868
|
module.exports = coerce;
|
|
869
869
|
}
|
|
@@ -1880,7 +1880,7 @@ var require_semver2 = __commonJS({
|
|
|
1880
1880
|
var constants = require_constants();
|
|
1881
1881
|
var SemVer = require_semver();
|
|
1882
1882
|
var identifiers = require_identifiers();
|
|
1883
|
-
var
|
|
1883
|
+
var parse3 = require_parse();
|
|
1884
1884
|
var valid = require_valid();
|
|
1885
1885
|
var clean = require_clean();
|
|
1886
1886
|
var inc = require_inc();
|
|
@@ -1918,7 +1918,7 @@ var require_semver2 = __commonJS({
|
|
|
1918
1918
|
var simplifyRange = require_simplify();
|
|
1919
1919
|
var subset = require_subset();
|
|
1920
1920
|
module.exports = {
|
|
1921
|
-
parse:
|
|
1921
|
+
parse: parse3,
|
|
1922
1922
|
valid,
|
|
1923
1923
|
clean,
|
|
1924
1924
|
inc,
|
|
@@ -2021,7 +2021,7 @@ var require_copy_to_clipboard = __commonJS({
|
|
|
2021
2021
|
var copyKey = (/mac os x/i.test(navigator.userAgent) ? "\u2318" : "Ctrl") + "+C";
|
|
2022
2022
|
return message.replace(/#{\s*key\s*}/g, copyKey);
|
|
2023
2023
|
}
|
|
2024
|
-
function copy(
|
|
2024
|
+
function copy(text3, options) {
|
|
2025
2025
|
var debug2, message, reselectPrevious, range, selection, mark, success = false;
|
|
2026
2026
|
if (!options) {
|
|
2027
2027
|
options = {};
|
|
@@ -2032,7 +2032,7 @@ var require_copy_to_clipboard = __commonJS({
|
|
|
2032
2032
|
range = document.createRange();
|
|
2033
2033
|
selection = document.getSelection();
|
|
2034
2034
|
mark = document.createElement("span");
|
|
2035
|
-
mark.textContent =
|
|
2035
|
+
mark.textContent = text3;
|
|
2036
2036
|
mark.ariaHidden = "true";
|
|
2037
2037
|
mark.style.all = "unset";
|
|
2038
2038
|
mark.style.position = "fixed";
|
|
@@ -2052,10 +2052,10 @@ var require_copy_to_clipboard = __commonJS({
|
|
|
2052
2052
|
debug2 && console.warn("trying IE specific stuff");
|
|
2053
2053
|
window.clipboardData.clearData();
|
|
2054
2054
|
var format3 = clipboardToIE11Formatting[options.format] || clipboardToIE11Formatting["default"];
|
|
2055
|
-
window.clipboardData.setData(format3,
|
|
2055
|
+
window.clipboardData.setData(format3, text3);
|
|
2056
2056
|
} else {
|
|
2057
2057
|
e2.clipboardData.clearData();
|
|
2058
|
-
e2.clipboardData.setData(options.format,
|
|
2058
|
+
e2.clipboardData.setData(options.format, text3);
|
|
2059
2059
|
}
|
|
2060
2060
|
}
|
|
2061
2061
|
if (options.onCopy) {
|
|
@@ -2075,14 +2075,14 @@ var require_copy_to_clipboard = __commonJS({
|
|
|
2075
2075
|
debug2 && console.error("unable to copy using execCommand: ", err);
|
|
2076
2076
|
debug2 && console.warn("trying IE specific stuff");
|
|
2077
2077
|
try {
|
|
2078
|
-
window.clipboardData.setData(options.format || "text",
|
|
2078
|
+
window.clipboardData.setData(options.format || "text", text3);
|
|
2079
2079
|
options.onCopy && options.onCopy(window.clipboardData);
|
|
2080
2080
|
success = true;
|
|
2081
2081
|
} catch (err2) {
|
|
2082
2082
|
debug2 && console.error("unable to copy using clipboardData: ", err2);
|
|
2083
2083
|
debug2 && console.error("falling back to prompt");
|
|
2084
2084
|
message = format2("message" in options ? options.message : defaultMessage);
|
|
2085
|
-
window.prompt(message,
|
|
2085
|
+
window.prompt(message, text3);
|
|
2086
2086
|
}
|
|
2087
2087
|
} finally {
|
|
2088
2088
|
if (selection) {
|
|
@@ -2421,7 +2421,7 @@ var init_event_streams = __esm({
|
|
|
2421
2421
|
});
|
|
2422
2422
|
|
|
2423
2423
|
// src/pages/spans-list-page.tsx
|
|
2424
|
-
import { Box as
|
|
2424
|
+
import { Box as Box23, Paper as Paper2 } from "@mui/material";
|
|
2425
2425
|
import { useCallback as useCallback12, useEffect as useEffect22, useMemo as useMemo13, useRef as useRef19, useState as useState22 } from "react";
|
|
2426
2426
|
|
|
2427
2427
|
// src/api/errors.ts
|
|
@@ -2491,8 +2491,10 @@ var EVENT_DETAILS_SERVICE_NAME_TEST_ID = "event-details-service-name";
|
|
|
2491
2491
|
var EVENT_DETAILS_OPERATION_NAME_TEST_ID = "event-details-operation-name";
|
|
2492
2492
|
var EVENT_DETAILS_CLOSE_BUTTON_TEST_ID = "event-details-close-button";
|
|
2493
2493
|
var EVENT_DETAILS_HEADING_TEST_ID = "event-details-heading";
|
|
2494
|
-
var
|
|
2495
|
-
var
|
|
2494
|
+
var EVENT_DETAILS_HEADING_STATUS_TEST_ID = "event-details-heading-status";
|
|
2495
|
+
var EVENT_DETAILS_HEADING_IAM_TEST_ID = "event-details-heading-iam";
|
|
2496
|
+
var EVENT_DETAILS_FUNCTION_ERROR_TEST_ID = "event-details-function-error";
|
|
2497
|
+
var EVENT_DETAILS_STACK_TRACE_TEST_ID = "event-details-stack-trace";
|
|
2496
2498
|
var EVENT_DETAILS_RESOURCE_NAME_TEST_ID = "event-details-resource-name";
|
|
2497
2499
|
var EVENT_DETAILS_RESOURCE_ARN_TEST_ID = "event-details-resource-arn";
|
|
2498
2500
|
var EVENT_DETAILS_CFN_RESOURCE_TYPE_TEST_ID = "event-details-cfn-resource-type";
|
|
@@ -7161,12 +7163,12 @@ var isColorString = (type, testProp) => (v) => {
|
|
|
7161
7163
|
var splitColor = (aName, bName, cName) => (v) => {
|
|
7162
7164
|
if (!isString(v))
|
|
7163
7165
|
return v;
|
|
7164
|
-
const [a3, b3, c3,
|
|
7166
|
+
const [a3, b3, c3, alpha7] = v.match(floatRegex);
|
|
7165
7167
|
return {
|
|
7166
7168
|
[aName]: parseFloat(a3),
|
|
7167
7169
|
[bName]: parseFloat(b3),
|
|
7168
7170
|
[cName]: parseFloat(c3),
|
|
7169
|
-
alpha:
|
|
7171
|
+
alpha: alpha7 !== void 0 ? parseFloat(alpha7) : 1
|
|
7170
7172
|
};
|
|
7171
7173
|
};
|
|
7172
7174
|
|
|
@@ -8280,7 +8282,7 @@ function hueToRgb(p, q, t) {
|
|
|
8280
8282
|
return p + (q - p) * (2 / 3 - t) * 6;
|
|
8281
8283
|
return p;
|
|
8282
8284
|
}
|
|
8283
|
-
function hslaToRgba({ hue, saturation, lightness, alpha:
|
|
8285
|
+
function hslaToRgba({ hue, saturation, lightness, alpha: alpha7 }) {
|
|
8284
8286
|
hue /= 360;
|
|
8285
8287
|
saturation /= 100;
|
|
8286
8288
|
lightness /= 100;
|
|
@@ -8300,7 +8302,7 @@ function hslaToRgba({ hue, saturation, lightness, alpha: alpha6 }) {
|
|
|
8300
8302
|
red: Math.round(red * 255),
|
|
8301
8303
|
green: Math.round(green * 255),
|
|
8302
8304
|
blue: Math.round(blue * 255),
|
|
8303
|
-
alpha:
|
|
8305
|
+
alpha: alpha7
|
|
8304
8306
|
};
|
|
8305
8307
|
}
|
|
8306
8308
|
|
|
@@ -13117,7 +13119,7 @@ var ResponsiveTimestampCell = memo3(({ date }) => {
|
|
|
13117
13119
|
|
|
13118
13120
|
// src/dev-settings.tsx
|
|
13119
13121
|
import * as React5 from "react";
|
|
13120
|
-
var DEFAULT_DEV_SETTINGS = { requestTerms: "on", waterfallIssueBackgrounds: "
|
|
13122
|
+
var DEFAULT_DEV_SETTINGS = { operationStatus: "subtitle-chips", requestTerms: "on", waterfallIssueBackgrounds: "off", waterfallLayout: "tree", waterfallStatusIcons: "first column" };
|
|
13121
13123
|
var DevSettingsContext = React5.createContext(DEFAULT_DEV_SETTINGS);
|
|
13122
13124
|
var useDevSettings = () => React5.useContext(DevSettingsContext);
|
|
13123
13125
|
|
|
@@ -13171,7 +13173,7 @@ var setQueryValues = (query2, key, { excluded, included }) => {
|
|
|
13171
13173
|
var removeExclusions = (query2) => (query2.match(TOKEN_PATTERN) ?? []).filter((token) => !isExclusion(token)).join(" ");
|
|
13172
13174
|
|
|
13173
13175
|
// src/components/cells/downstream-cell.tsx
|
|
13174
|
-
import { Cancel,
|
|
13176
|
+
import { Cancel, GppMaybe, SubdirectoryArrowRight } from "@mui/icons-material";
|
|
13175
13177
|
import { Box, Tooltip, Typography } from "@mui/material";
|
|
13176
13178
|
import { alpha as alpha2 } from "@mui/material/styles";
|
|
13177
13179
|
|
|
@@ -13253,7 +13255,7 @@ var DownstreamCell = ({ downstream }) => {
|
|
|
13253
13255
|
pluralize(downstream.count, "op")
|
|
13254
13256
|
] }),
|
|
13255
13257
|
downstream.errors > 0 && /* @__PURE__ */ jsx4(IssueChip, { color: "error", count: downstream.errors, icon: /* @__PURE__ */ jsx4(Cancel, { sx: { fontSize: 12 } }) }),
|
|
13256
|
-
downstream.warnings > 0 && /* @__PURE__ */ jsx4(IssueChip, { color: "warning", count: downstream.warnings, icon: /* @__PURE__ */ jsx4(
|
|
13258
|
+
downstream.warnings > 0 && /* @__PURE__ */ jsx4(IssueChip, { color: "warning", count: downstream.warnings, icon: /* @__PURE__ */ jsx4(GppMaybe, { sx: { fontSize: 12 } }) })
|
|
13257
13259
|
] }) });
|
|
13258
13260
|
};
|
|
13259
13261
|
|
|
@@ -15366,7 +15368,7 @@ var ServiceCell = memo7(({
|
|
|
15366
15368
|
ServiceCell.displayName = "ServiceCell";
|
|
15367
15369
|
|
|
15368
15370
|
// src/components/cells/status-cell.tsx
|
|
15369
|
-
import { Cancel as Cancel2,
|
|
15371
|
+
import { Cancel as Cancel2, GppMaybe as GppMaybe2 } from "@mui/icons-material";
|
|
15370
15372
|
import { Box as Box3, Divider, Tooltip as Tooltip3, Typography as Typography3 } from "@mui/material";
|
|
15371
15373
|
|
|
15372
15374
|
// src/utils/iam-utils.ts
|
|
@@ -15539,7 +15541,7 @@ var StatusIconWithTooltip = ({ span }) => {
|
|
|
15539
15541
|
if (!error && !warning2) return /* @__PURE__ */ jsx125(Fragment2, {});
|
|
15540
15542
|
return /* @__PURE__ */ jsx125(Tooltip3, { title: buildTooltipContent(span), children: /* @__PURE__ */ jsxs120(Box3, { sx: { alignItems: "center", cursor: "default", display: "flex" }, children: [
|
|
15541
15543
|
error && /* @__PURE__ */ jsx125(Box3, { "aria-label": "Error", role: "img", sx: { display: "flex" }, children: /* @__PURE__ */ jsx125(Cancel2, { sx: { color: "error.main" } }) }),
|
|
15542
|
-
warning2 && /* @__PURE__ */ jsx125(Box3, { "aria-label": "Warning", role: "img", sx: { display: "flex" }, children: /* @__PURE__ */ jsx125(
|
|
15544
|
+
warning2 && /* @__PURE__ */ jsx125(Box3, { "aria-label": "Warning", role: "img", sx: { display: "flex" }, children: /* @__PURE__ */ jsx125(GppMaybe2, { sx: { color: "warning.main" } }) })
|
|
15543
15545
|
] }) });
|
|
15544
15546
|
};
|
|
15545
15547
|
|
|
@@ -15560,9 +15562,12 @@ var fmtLimit = (value) => {
|
|
|
15560
15562
|
if (value === "unlimited") return "Unlimited";
|
|
15561
15563
|
return fmt(value);
|
|
15562
15564
|
};
|
|
15563
|
-
var StatRow = ({ label, value }) => /* @__PURE__ */ jsxs121(Box4, { sx: { alignItems: "baseline", display: "flex", justifyContent: "space-between", minWidth: 220 }, children: [
|
|
15565
|
+
var StatRow = ({ label, unit, value }) => /* @__PURE__ */ jsxs121(Box4, { sx: { alignItems: "baseline", display: "flex", justifyContent: "space-between", minWidth: 220 }, children: [
|
|
15564
15566
|
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", sx: { mr: 4 }, variant: "caption", children: label }),
|
|
15565
|
-
/* @__PURE__ */
|
|
15567
|
+
/* @__PURE__ */ jsxs121(Box4, { sx: { alignItems: "baseline", display: "flex", gap: 0.5 }, children: [
|
|
15568
|
+
/* @__PURE__ */ jsx126(Typography4, { fontWeight: 600, variant: "body2", children: fmtLimit(value) }),
|
|
15569
|
+
value !== void 0 && /* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", variant: "caption", children: value === 1 ? unit : `${unit}s` })
|
|
15570
|
+
] })
|
|
15566
15571
|
] });
|
|
15567
15572
|
var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) => {
|
|
15568
15573
|
const [anchorElement, setAnchorElement] = useState4();
|
|
@@ -15579,12 +15584,12 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15579
15584
|
isLoading ? /* @__PURE__ */ jsx126(Skeleton, { sx: { minWidth: 120 } }) : /* @__PURE__ */ jsxs121(Box4, { sx: { alignItems: "baseline", display: "flex", gap: 0.5 }, children: [
|
|
15580
15585
|
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", variant: "caption", children: "Showing" }),
|
|
15581
15586
|
/* @__PURE__ */ jsx126(Typography4, { variant: "body2", children: visibleCount === void 0 ? "\u2014" : fmt(visibleCount) }),
|
|
15582
|
-
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", variant: "caption", children: "
|
|
15587
|
+
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", variant: "caption", children: visibleCount === 1 ? "request" : "requests" })
|
|
15583
15588
|
] }),
|
|
15584
|
-
/* @__PURE__ */ jsx126(Tooltip4, { title: "
|
|
15589
|
+
/* @__PURE__ */ jsx126(Tooltip4, { title: "Count details", children: /* @__PURE__ */ jsx126(
|
|
15585
15590
|
IconButton,
|
|
15586
15591
|
{
|
|
15587
|
-
"aria-describedby": isOpen ? "
|
|
15592
|
+
"aria-describedby": isOpen ? "count-popover" : void 0,
|
|
15588
15593
|
onClick: (event) => {
|
|
15589
15594
|
setAnchorElement(isOpen ? void 0 : event.currentTarget);
|
|
15590
15595
|
},
|
|
@@ -15598,7 +15603,7 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15598
15603
|
{
|
|
15599
15604
|
anchorEl: anchorElement,
|
|
15600
15605
|
anchorOrigin: { horizontal: "right", vertical: "bottom" },
|
|
15601
|
-
id: "
|
|
15606
|
+
id: "count-popover",
|
|
15602
15607
|
onClose: () => {
|
|
15603
15608
|
setAnchorElement(void 0);
|
|
15604
15609
|
},
|
|
@@ -15606,14 +15611,25 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15606
15611
|
transformOrigin: { horizontal: "right", vertical: "top" },
|
|
15607
15612
|
children: /* @__PURE__ */ jsxs121(Box4, { sx: { minWidth: 240, p: 2 }, children: [
|
|
15608
15613
|
/* @__PURE__ */ jsx126(Typography4, { fontWeight: 700, variant: "body2", children: "Storage" }),
|
|
15609
|
-
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", sx: { mt: 0.25 }, variant: "caption", children: "
|
|
15610
|
-
/* @__PURE__ */
|
|
15611
|
-
|
|
15612
|
-
|
|
15613
|
-
|
|
15614
|
-
|
|
15615
|
-
|
|
15616
|
-
|
|
15614
|
+
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", sx: { mt: 0.25 }, variant: "caption", children: "Each request groups the operations it caused. Limits count operations." }),
|
|
15615
|
+
/* @__PURE__ */ jsxs121(Box4, { sx: { display: "flex", flexDirection: "column", gap: 0.75, mt: 1.5 }, children: [
|
|
15616
|
+
/* @__PURE__ */ jsx126(
|
|
15617
|
+
StatRow,
|
|
15618
|
+
{
|
|
15619
|
+
label: /* @__PURE__ */ jsx126(Tooltip4, { placement: "left", title: "The number of requests currently listed.", children: /* @__PURE__ */ jsx126(Box4, { component: "span", sx: { borderBottom: "1px dashed", borderColor: "text.secondary", cursor: "help" }, children: "Requests shown" }) }),
|
|
15620
|
+
unit: "request",
|
|
15621
|
+
value: visibleCount
|
|
15622
|
+
}
|
|
15623
|
+
),
|
|
15624
|
+
/* @__PURE__ */ jsx126(
|
|
15625
|
+
StatRow,
|
|
15626
|
+
{
|
|
15627
|
+
label: /* @__PURE__ */ jsx126(Tooltip4, { placement: "left", title: "The number of operations stored, including the downstream operations of each request.", children: /* @__PURE__ */ jsx126(Box4, { component: "span", sx: { borderBottom: "1px dashed", borderColor: "text.secondary", cursor: "help" }, children: "Operations stored" }) }),
|
|
15628
|
+
unit: "op",
|
|
15629
|
+
value: totalCount
|
|
15630
|
+
}
|
|
15631
|
+
)
|
|
15632
|
+
] }),
|
|
15617
15633
|
(systemLimitReached || licenseLimit !== void 0 && licenseLimit !== "unlimited") && /* @__PURE__ */ jsxs121(Fragment3, { children: [
|
|
15618
15634
|
/* @__PURE__ */ jsx126(Divider2, { sx: { my: 1.5 } }),
|
|
15619
15635
|
/* @__PURE__ */ jsx126(Typography4, { color: "text.secondary", fontWeight: 600, variant: "caption", children: "Limits" }),
|
|
@@ -15623,6 +15639,7 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15623
15639
|
StatRow,
|
|
15624
15640
|
{
|
|
15625
15641
|
label: /* @__PURE__ */ jsx126(Tooltip4, { placement: "left", title: "The maximum number of operations allowed by your current license.", children: /* @__PURE__ */ jsx126(Box4, { component: "span", sx: { borderBottom: "1px dashed", borderColor: "text.secondary", cursor: "help" }, children: "License limit" }) }),
|
|
15642
|
+
unit: "op",
|
|
15626
15643
|
value: licenseLimit
|
|
15627
15644
|
}
|
|
15628
15645
|
),
|
|
@@ -15630,6 +15647,7 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15630
15647
|
StatRow,
|
|
15631
15648
|
{
|
|
15632
15649
|
label: /* @__PURE__ */ jsx126(Tooltip4, { placement: "left", title: "The maximum number of operations that can be stored in the system.", children: /* @__PURE__ */ jsx126(Box4, { component: "span", sx: { borderBottom: "1px dashed", borderColor: "text.secondary", cursor: "help" }, children: "System limit" }) }),
|
|
15650
|
+
unit: "op",
|
|
15633
15651
|
value: systemLimit
|
|
15634
15652
|
}
|
|
15635
15653
|
)
|
|
@@ -15667,7 +15685,7 @@ var SpanCountBadge = ({ licenseLimit, systemLimit, totalCount, visibleCount }) =
|
|
|
15667
15685
|
};
|
|
15668
15686
|
|
|
15669
15687
|
// src/components/spans-list/spans-filter-bar.tsx
|
|
15670
|
-
import { ArrowDropDown, Cancel as Cancel3, FilterList, Visibility, VisibilityOff
|
|
15688
|
+
import { ArrowDropDown, Cancel as Cancel3, FilterList, GppMaybe as GppMaybe3, Visibility, VisibilityOff } from "@mui/icons-material";
|
|
15671
15689
|
import {
|
|
15672
15690
|
Box as Box5,
|
|
15673
15691
|
Button as Button2,
|
|
@@ -15845,7 +15863,7 @@ var StatusFilter = ({ counts, onChange, value }) => {
|
|
|
15845
15863
|
/* @__PURE__ */ jsx127(StatusCount, { count: counts.error, "data-testid": ERROR_COUNT_TEST_ID })
|
|
15846
15864
|
] }),
|
|
15847
15865
|
/* @__PURE__ */ jsxs122(ToggleButton, { value: "warning", children: [
|
|
15848
|
-
/* @__PURE__ */ jsx127(
|
|
15866
|
+
/* @__PURE__ */ jsx127(GppMaybe3, { sx: { color: "warning.main", fontSize: 16 } }),
|
|
15849
15867
|
"Warnings",
|
|
15850
15868
|
/* @__PURE__ */ jsx127(StatusCount, { count: counts.warning, "data-testid": WARNING_COUNT_TEST_ID })
|
|
15851
15869
|
] })
|
|
@@ -16223,7 +16241,7 @@ var SpansDataGrid = ({
|
|
|
16223
16241
|
{
|
|
16224
16242
|
licenseLimit,
|
|
16225
16243
|
systemLimit,
|
|
16226
|
-
totalCount
|
|
16244
|
+
totalCount,
|
|
16227
16245
|
visibleCount: spans?.length
|
|
16228
16246
|
}
|
|
16229
16247
|
),
|
|
@@ -16729,13 +16747,13 @@ var getTraceBounds = (spans) => {
|
|
|
16729
16747
|
|
|
16730
16748
|
// src/components/trace-panel/trace-sidebar.tsx
|
|
16731
16749
|
import { Close as Close4 } from "@mui/icons-material";
|
|
16732
|
-
import { Box as
|
|
16750
|
+
import { Box as Box21, IconButton as IconButton8, ToggleButton as ToggleButton3, ToggleButtonGroup as ToggleButtonGroup3, Typography as Typography16 } from "@mui/material";
|
|
16733
16751
|
import { ReactFlowProvider } from "@xyflow/react";
|
|
16734
16752
|
import * as React125 from "react";
|
|
16735
16753
|
|
|
16736
16754
|
// src/components/event-details/event-details.tsx
|
|
16737
|
-
import { Cancel as
|
|
16738
|
-
import { Alert as Alert4, Box as
|
|
16755
|
+
import { Cancel as Cancel6, Close as Close3, GppBad as GppBad2, GppMaybe as GppMaybe7 } from "@mui/icons-material";
|
|
16756
|
+
import { Alert as Alert4, Box as Box17, FormControlLabel, IconButton as IconButton6, Stack as Stack4, Switch, Tab, Tabs, Typography as Typography13 } from "@mui/material";
|
|
16739
16757
|
import { useMemo as useMemo10, useState as useState13 } from "react";
|
|
16740
16758
|
|
|
16741
16759
|
// src/utils/event-utils.ts
|
|
@@ -16845,6 +16863,37 @@ var getEventGroupsByType = (events) => {
|
|
|
16845
16863
|
return groups;
|
|
16846
16864
|
};
|
|
16847
16865
|
|
|
16866
|
+
// src/utils/lambda-function-error.ts
|
|
16867
|
+
var parse2 = (value) => {
|
|
16868
|
+
if (typeof value !== "string") return value;
|
|
16869
|
+
try {
|
|
16870
|
+
return JSON.parse(value);
|
|
16871
|
+
} catch {
|
|
16872
|
+
return value;
|
|
16873
|
+
}
|
|
16874
|
+
};
|
|
16875
|
+
var text2 = (value) => {
|
|
16876
|
+
if (value === void 0 || value === null || value === "") return void 0;
|
|
16877
|
+
return typeof value === "string" ? value : JSON.stringify(value);
|
|
16878
|
+
};
|
|
16879
|
+
var getLambdaFunctionError = (response) => {
|
|
16880
|
+
const parsed = parse2(response);
|
|
16881
|
+
if (!parsed || typeof parsed !== "object" || !("FunctionError" in parsed) || typeof parsed.FunctionError !== "string") {
|
|
16882
|
+
return void 0;
|
|
16883
|
+
}
|
|
16884
|
+
const payload = "Payload" in parsed ? parse2(parsed.Payload) : void 0;
|
|
16885
|
+
const error = payload && typeof payload === "object" ? payload : {};
|
|
16886
|
+
const stackTrace = Array.isArray(error.stackTrace) && error.stackTrace.length > 0 ? error.stackTrace.map((frame2) => String(frame2).replace(/\n$/, "")).join("\n") : void 0;
|
|
16887
|
+
return {
|
|
16888
|
+
// A runtime that returns a non-JSON payload: show it as the message.
|
|
16889
|
+
errorMessage: text2(error.errorMessage) ?? (typeof payload === "string" ? text2(payload) : void 0),
|
|
16890
|
+
errorType: text2(error.errorType),
|
|
16891
|
+
functionError: parsed.FunctionError,
|
|
16892
|
+
requestId: text2(error.requestId),
|
|
16893
|
+
stackTrace
|
|
16894
|
+
};
|
|
16895
|
+
};
|
|
16896
|
+
|
|
16848
16897
|
// src/utils/time.ts
|
|
16849
16898
|
function unixNanoToDate(unixNanoString) {
|
|
16850
16899
|
const milliseconds = unixNanoToMilliseconds(unixNanoString);
|
|
@@ -16864,8 +16913,8 @@ import { jsx as jsx131 } from "react/jsx-runtime";
|
|
|
16864
16913
|
var CopyButton = ({ value }) => {
|
|
16865
16914
|
const [copied, setCopied] = useState8(false);
|
|
16866
16915
|
const handleCopy = useCallback3(() => {
|
|
16867
|
-
const
|
|
16868
|
-
void navigator.clipboard.writeText(
|
|
16916
|
+
const text3 = typeof value === "string" ? value : JSON.stringify(value, void 0, 2);
|
|
16917
|
+
void navigator.clipboard.writeText(text3).then(() => {
|
|
16869
16918
|
setCopied(true);
|
|
16870
16919
|
setTimeout(() => {
|
|
16871
16920
|
setCopied(false);
|
|
@@ -16890,7 +16939,7 @@ import { Box as Box14, IconButton as IconButton5, Typography as Typography10 } f
|
|
|
16890
16939
|
import { useEffect as useEffect12, useMemo as useMemo7, useRef as useRef8, useState as useState10 } from "react";
|
|
16891
16940
|
|
|
16892
16941
|
// src/components/status-icon.tsx
|
|
16893
|
-
import { Cancel as Cancel4, CheckCircle,
|
|
16942
|
+
import { Cancel as Cancel4, CheckCircle, GppMaybe as GppMaybe4, Info } from "@mui/icons-material";
|
|
16894
16943
|
import { Box as Box9 } from "@mui/material";
|
|
16895
16944
|
import { jsx as jsx132 } from "react/jsx-runtime";
|
|
16896
16945
|
var StatusIcon = ({ errorLevel }) => {
|
|
@@ -16903,7 +16952,7 @@ var StatusIcon = ({ errorLevel }) => {
|
|
|
16903
16952
|
}
|
|
16904
16953
|
case EventLevel.LevelPermission:
|
|
16905
16954
|
case EventLevel.LevelWarning: {
|
|
16906
|
-
return /* @__PURE__ */ jsx132(
|
|
16955
|
+
return /* @__PURE__ */ jsx132(GppMaybe4, { sx: { color: "orange" } });
|
|
16907
16956
|
}
|
|
16908
16957
|
default: {
|
|
16909
16958
|
return /* @__PURE__ */ jsx132(CheckCircle, { sx: { color: "lightgray" } });
|
|
@@ -16912,7 +16961,7 @@ var StatusIcon = ({ errorLevel }) => {
|
|
|
16912
16961
|
};
|
|
16913
16962
|
|
|
16914
16963
|
// src/components/event-details/iam-event-detail.tsx
|
|
16915
|
-
import { CheckCircle as CheckCircle2, Error as
|
|
16964
|
+
import { CheckCircle as CheckCircle2, Error as ErrorIcon, GppMaybe as GppMaybe5 } from "@mui/icons-material";
|
|
16916
16965
|
import { Box as Box10, Chip, Typography as Typography8 } from "@mui/material";
|
|
16917
16966
|
import { jsx as jsx133, jsxs as jsxs126 } from "react/jsx-runtime";
|
|
16918
16967
|
var DetailRow = ({ content, label }) => /* @__PURE__ */ jsxs126(Box10, { sx: { display: "grid", gap: 1, gridTemplateColumns: "72px 1fr", mb: 0.5 }, children: [
|
|
@@ -16925,10 +16974,10 @@ var PermissionIcon = ({ status }) => {
|
|
|
16925
16974
|
return /* @__PURE__ */ jsx133(CheckCircle2, { sx: { color: "success.main", fontSize: "1rem" } });
|
|
16926
16975
|
}
|
|
16927
16976
|
case "explicitly_denied": {
|
|
16928
|
-
return /* @__PURE__ */ jsx133(
|
|
16977
|
+
return /* @__PURE__ */ jsx133(ErrorIcon, { sx: { color: "error.main", fontSize: "1rem" } });
|
|
16929
16978
|
}
|
|
16930
16979
|
case "implicitly_denied": {
|
|
16931
|
-
return /* @__PURE__ */ jsx133(
|
|
16980
|
+
return /* @__PURE__ */ jsx133(GppMaybe5, { sx: { color: "warning.main", fontSize: "1rem" } });
|
|
16932
16981
|
}
|
|
16933
16982
|
}
|
|
16934
16983
|
};
|
|
@@ -16992,15 +17041,10 @@ var IAMEventDetail = ({ event }) => {
|
|
|
16992
17041
|
};
|
|
16993
17042
|
|
|
16994
17043
|
// src/components/event-details/iam-permission-detail.tsx
|
|
16995
|
-
import { Box as Box11,
|
|
17044
|
+
import { Box as Box11, Stack as Stack2, Typography as Typography9 } from "@mui/material";
|
|
16996
17045
|
import { useMemo as useMemo5 } from "react";
|
|
16997
17046
|
import { jsx as jsx134, jsxs as jsxs127 } from "react/jsx-runtime";
|
|
16998
|
-
var
|
|
16999
|
-
if (isAllowed) return "success.main";
|
|
17000
|
-
if (spanStatusCode === 2) return "error.main";
|
|
17001
|
-
return "warning.main";
|
|
17002
|
-
};
|
|
17003
|
-
var IAMPermissionItem = ({ event, spanStatusCode }) => {
|
|
17047
|
+
var IAMPermissionItem = ({ event }) => {
|
|
17004
17048
|
const parsedData = useMemo5(() => {
|
|
17005
17049
|
const payloadString = event.attributes?.payload;
|
|
17006
17050
|
if (!payloadString) return;
|
|
@@ -17012,36 +17056,31 @@ var IAMPermissionItem = ({ event, spanStatusCode }) => {
|
|
|
17012
17056
|
return null;
|
|
17013
17057
|
}
|
|
17014
17058
|
const { parsedIAM } = parsedData;
|
|
17015
|
-
|
|
17016
|
-
|
|
17017
|
-
|
|
17018
|
-
|
|
17019
|
-
|
|
17020
|
-
|
|
17021
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Principal" }),
|
|
17022
|
-
/* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17023
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { wordBreak: "break-all" }, variant: "body2", children: parsedIAM.principal }),
|
|
17024
|
-
/* @__PURE__ */ jsx134(CopyButton, { value: parsedIAM.principal })
|
|
17025
|
-
] })
|
|
17026
|
-
] }),
|
|
17027
|
-
parsedIAM.details.actions && parsedIAM.details.actions.length > 0 && /* @__PURE__ */ jsxs127(Box11, { "data-testid": EVENT_DETAILS_IAM_ACTIONS_TEST_ID, children: [
|
|
17028
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Actions" }),
|
|
17029
|
-
parsedIAM.details.actions.map((action) => /* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17030
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block" }, variant: "body2", children: action }),
|
|
17031
|
-
/* @__PURE__ */ jsx134(CopyButton, { value: action })
|
|
17032
|
-
] }, action))
|
|
17033
|
-
] }),
|
|
17034
|
-
parsedIAM.details.resources && parsedIAM.details.resources.length > 0 && /* @__PURE__ */ jsxs127(Box11, { "data-testid": EVENT_DETAILS_IAM_RESOURCES_TEST_ID, children: [
|
|
17035
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Resources" }),
|
|
17036
|
-
parsedIAM.details.resources.map((resource) => /* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17037
|
-
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", wordBreak: "break-all" }, variant: "body2", children: resource }),
|
|
17038
|
-
/* @__PURE__ */ jsx134(CopyButton, { value: resource })
|
|
17039
|
-
] }, resource))
|
|
17059
|
+
return /* @__PURE__ */ jsx134(Box11, { sx: { mb: 0.5 }, children: /* @__PURE__ */ jsxs127(Stack2, { spacing: 1, children: [
|
|
17060
|
+
/* @__PURE__ */ jsxs127(Box11, { "data-testid": EVENT_DETAILS_IAM_PRINCIPAL_TEST_ID, children: [
|
|
17061
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Principal" }),
|
|
17062
|
+
/* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17063
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { wordBreak: "break-all" }, variant: "body2", children: parsedIAM.principal }),
|
|
17064
|
+
/* @__PURE__ */ jsx134(CopyButton, { value: parsedIAM.principal })
|
|
17040
17065
|
] })
|
|
17066
|
+
] }),
|
|
17067
|
+
parsedIAM.details.actions && parsedIAM.details.actions.length > 0 && /* @__PURE__ */ jsxs127(Box11, { "data-testid": EVENT_DETAILS_IAM_ACTIONS_TEST_ID, children: [
|
|
17068
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Actions" }),
|
|
17069
|
+
parsedIAM.details.actions.map((action) => /* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17070
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block" }, variant: "body2", children: action }),
|
|
17071
|
+
/* @__PURE__ */ jsx134(CopyButton, { value: action })
|
|
17072
|
+
] }, action))
|
|
17073
|
+
] }),
|
|
17074
|
+
parsedIAM.details.resources && parsedIAM.details.resources.length > 0 && /* @__PURE__ */ jsxs127(Box11, { "data-testid": EVENT_DETAILS_IAM_RESOURCES_TEST_ID, children: [
|
|
17075
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", fontWeight: 600 }, variant: "caption", children: "Resources" }),
|
|
17076
|
+
parsedIAM.details.resources.map((resource) => /* @__PURE__ */ jsxs127(Stack2, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
17077
|
+
/* @__PURE__ */ jsx134(Typography9, { sx: { display: "block", wordBreak: "break-all" }, variant: "body2", children: resource }),
|
|
17078
|
+
/* @__PURE__ */ jsx134(CopyButton, { value: resource })
|
|
17079
|
+
] }, resource))
|
|
17041
17080
|
] })
|
|
17042
|
-
] });
|
|
17081
|
+
] }) });
|
|
17043
17082
|
};
|
|
17044
|
-
var IAMPermissionDetail = ({ events
|
|
17083
|
+
var IAMPermissionDetail = ({ events }) => /* @__PURE__ */ jsx134(Box11, { children: events.map((event) => /* @__PURE__ */ jsx134(IAMPermissionItem, { event }, `${event.span_id}-${event.event_id}`)) });
|
|
17045
17084
|
|
|
17046
17085
|
// src/components/event-details/payload-viewer.tsx
|
|
17047
17086
|
import { Box as Box13, useTheme as useTheme3 } from "@mui/material";
|
|
@@ -18982,11 +19021,10 @@ var getEventLevelFromGroup = (group3) => {
|
|
|
18982
19021
|
var EventDetail = ({
|
|
18983
19022
|
displayText,
|
|
18984
19023
|
events,
|
|
18985
|
-
spanStatusCode,
|
|
18986
19024
|
type
|
|
18987
19025
|
}) => {
|
|
18988
19026
|
if (type === "permission") {
|
|
18989
|
-
return /* @__PURE__ */ jsx137(IAMPermissionDetail, { events
|
|
19027
|
+
return /* @__PURE__ */ jsx137(IAMPermissionDetail, { events });
|
|
18990
19028
|
}
|
|
18991
19029
|
const eventLevel = getEventLevelFromGroup(type);
|
|
18992
19030
|
return /* @__PURE__ */ jsxs129(Box14, { children: [
|
|
@@ -26007,7 +26045,7 @@ var ProtocolLib = class {
|
|
|
26007
26045
|
if (output !== void 0 && queryErrorHeader != null) {
|
|
26008
26046
|
const [Code, Type] = queryErrorHeader.split(";");
|
|
26009
26047
|
const keys = Object.keys(output);
|
|
26010
|
-
const
|
|
26048
|
+
const Error2 = {
|
|
26011
26049
|
Code,
|
|
26012
26050
|
Type
|
|
26013
26051
|
};
|
|
@@ -26015,10 +26053,10 @@ var ProtocolLib = class {
|
|
|
26015
26053
|
output.Type = Type;
|
|
26016
26054
|
for (let i2 = 0; i2 < keys.length; i2++) {
|
|
26017
26055
|
const k2 = keys[i2];
|
|
26018
|
-
|
|
26056
|
+
Error2[k2 === "message" ? "Message" : k2] = output[k2];
|
|
26019
26057
|
}
|
|
26020
|
-
delete
|
|
26021
|
-
output.Error =
|
|
26058
|
+
delete Error2.__type;
|
|
26059
|
+
output.Error = Error2;
|
|
26022
26060
|
}
|
|
26023
26061
|
}
|
|
26024
26062
|
queryCompatOutput(queryCompatErrorData, errorData) {
|
|
@@ -31107,10 +31145,10 @@ UAItem.prototype.parseCH = function() {
|
|
|
31107
31145
|
break;
|
|
31108
31146
|
case RESULT2:
|
|
31109
31147
|
var data = this.data;
|
|
31110
|
-
var
|
|
31148
|
+
var parse3 = function(itemType) {
|
|
31111
31149
|
return data[itemType].getItem().setCH(uaCH).parseCH().get();
|
|
31112
31150
|
};
|
|
31113
|
-
this.set(BROWSER,
|
|
31151
|
+
this.set(BROWSER, parse3(BROWSER)).set(CPU, parse3(CPU)).set(DEVICE, parse3(DEVICE)).set(ENGINE, parse3(ENGINE)).set(OS, parse3(OS));
|
|
31114
31152
|
}
|
|
31115
31153
|
return this;
|
|
31116
31154
|
};
|
|
@@ -31402,8 +31440,110 @@ var LambdaInvokeLogsSection = ({ endTimeNano, functionName: functionName2, regio
|
|
|
31402
31440
|
return /* @__PURE__ */ jsx141(Box15, { sx: { backgroundColor: (theme) => theme.palette.background.default, borderRadius: 1, p: 1 }, children: /* @__PURE__ */ jsx141("pre", { style: { margin: 0, overflow: "auto" }, children: logs.map((log) => /* @__PURE__ */ jsx141(Typography11, { variant: "body2", children: `[${log.timestamp}] ${log.message}` }, log.ptr)) }) });
|
|
31403
31441
|
};
|
|
31404
31442
|
|
|
31443
|
+
// src/components/event-details/operation-status-badges.tsx
|
|
31444
|
+
import { Cancel as Cancel5, CheckCircle as CheckCircle3, GppBad, GppGood, GppMaybe as GppMaybe6, HelpOutline } from "@mui/icons-material";
|
|
31445
|
+
import { alpha as alpha5, Box as Box16, ButtonBase, Chip as Chip2, darken, lighten, Tooltip as Tooltip6, Typography as Typography12 } from "@mui/material";
|
|
31446
|
+
import { jsx as jsx142, jsxs as jsxs131 } from "react/jsx-runtime";
|
|
31447
|
+
var IAM = {
|
|
31448
|
+
allowed: { color: "success", icon: GppGood, label: "IAM allowed", title: "IAM allowed the call" },
|
|
31449
|
+
denied: { color: "error", icon: GppBad, label: "IAM denied", title: "IAM denied and blocked the call" },
|
|
31450
|
+
suppressed: { color: "text", icon: HelpOutline, label: "IAM hidden", title: "IAM results are hidden: upgrade your license to view" },
|
|
31451
|
+
warning: { color: "warning", icon: GppMaybe6, label: "IAM warning", title: "IAM denied the call, but enforcement is off, so it went through" }
|
|
31452
|
+
};
|
|
31453
|
+
var sentenceCase = (text3) => text3.charAt(0) + text3.slice(1).toLowerCase();
|
|
31454
|
+
var paletteColor = (color2) => color2 === "text" ? "text.secondary" : `${color2}.main`;
|
|
31455
|
+
var tint = (color2) => ({
|
|
31456
|
+
bgcolor: (theme) => color2 === "text" ? theme.palette.action.hover : alpha5(theme.palette[color2].main, 0.12),
|
|
31457
|
+
borderRadius: 1,
|
|
31458
|
+
color: (theme) => {
|
|
31459
|
+
if (color2 === "text") return theme.palette.text.primary;
|
|
31460
|
+
const main = theme.palette[color2].main;
|
|
31461
|
+
return theme.palette.mode === "dark" ? lighten(main, 0.55) : darken(main, 0.45);
|
|
31462
|
+
},
|
|
31463
|
+
px: 0.75,
|
|
31464
|
+
py: 0.25
|
|
31465
|
+
});
|
|
31466
|
+
var clickable = (onClick, isTinted) => onClick === void 0 ? {} : {
|
|
31467
|
+
component: ButtonBase,
|
|
31468
|
+
onClick,
|
|
31469
|
+
sx: { "&:hover": isTinted ? { filter: "brightness(1.15)" } : { textDecoration: "underline" }, "borderRadius": 1, "cursor": "pointer", "font": "inherit" }
|
|
31470
|
+
};
|
|
31471
|
+
var OperationStatusBadges = ({ iam, iamPermission, onIamClick, onStatusClick, status, statusLabel, variant }) => {
|
|
31472
|
+
const isError = status === "error";
|
|
31473
|
+
const statusText = isError ? statusLabel ?? "Error" : "OK";
|
|
31474
|
+
const StatusIcon2 = isError ? Cancel5 : CheckCircle3;
|
|
31475
|
+
const statusColor = isError ? "error" : "success";
|
|
31476
|
+
const iamStyle = iam === void 0 ? void 0 : IAM[iam];
|
|
31477
|
+
const iamPrefix = variant === "subtitle-chips" ? "" : "IAM \u2022 ";
|
|
31478
|
+
const iamLabel = iamPermission === void 0 || iam === "suppressed" ? iamStyle?.label : `${iamPrefix}${sentenceCase(formatPermissionStatus(iamPermission))}`;
|
|
31479
|
+
const showStatus = status !== "unset";
|
|
31480
|
+
if (variant === "chips") {
|
|
31481
|
+
return /* @__PURE__ */ jsxs131(Box16, { sx: { display: "flex", flex: "none", gap: 0.5 }, children: [
|
|
31482
|
+
showStatus && /* @__PURE__ */ jsx142(
|
|
31483
|
+
Chip2,
|
|
31484
|
+
{
|
|
31485
|
+
color: statusColor,
|
|
31486
|
+
"data-testid": EVENT_DETAILS_HEADING_STATUS_TEST_ID,
|
|
31487
|
+
icon: /* @__PURE__ */ jsx142(StatusIcon2, {}),
|
|
31488
|
+
label: statusText,
|
|
31489
|
+
size: "small",
|
|
31490
|
+
variant: "outlined"
|
|
31491
|
+
}
|
|
31492
|
+
),
|
|
31493
|
+
iamStyle && /* @__PURE__ */ jsx142(Tooltip6, { title: iamStyle.title, children: /* @__PURE__ */ jsx142(
|
|
31494
|
+
Chip2,
|
|
31495
|
+
{
|
|
31496
|
+
color: iamStyle.color === "text" ? "default" : iamStyle.color,
|
|
31497
|
+
"data-testid": EVENT_DETAILS_HEADING_IAM_TEST_ID,
|
|
31498
|
+
icon: /* @__PURE__ */ jsx142(iamStyle.icon, {}),
|
|
31499
|
+
label: iamLabel,
|
|
31500
|
+
size: "small",
|
|
31501
|
+
variant: "outlined"
|
|
31502
|
+
}
|
|
31503
|
+
) })
|
|
31504
|
+
] });
|
|
31505
|
+
}
|
|
31506
|
+
if (variant === "icons") {
|
|
31507
|
+
return /* @__PURE__ */ jsxs131(Box16, { sx: { alignItems: "center", display: "flex", flex: "none", gap: 0.25 }, children: [
|
|
31508
|
+
showStatus && /* @__PURE__ */ jsx142(Tooltip6, { title: isError ? `Failed: ${statusText}` : "Succeeded", children: /* @__PURE__ */ jsx142(StatusIcon2, { color: statusColor, "data-testid": EVENT_DETAILS_HEADING_STATUS_TEST_ID, fontSize: "small" }) }),
|
|
31509
|
+
iamStyle && /* @__PURE__ */ jsx142(Tooltip6, { title: iamStyle.title, children: /* @__PURE__ */ jsx142(iamStyle.icon, { "data-testid": EVENT_DETAILS_HEADING_IAM_TEST_ID, fontSize: "small", sx: { color: paletteColor(iamStyle.color) } }) })
|
|
31510
|
+
] });
|
|
31511
|
+
}
|
|
31512
|
+
const isTinted = variant === "subtitle-chips";
|
|
31513
|
+
if (!showStatus && !iamStyle) {
|
|
31514
|
+
return null;
|
|
31515
|
+
}
|
|
31516
|
+
return /* @__PURE__ */ jsxs131(Box16, { sx: { alignItems: "center", display: "flex", gap: 1, minWidth: 0 }, children: [
|
|
31517
|
+
showStatus && /* @__PURE__ */ jsxs131(
|
|
31518
|
+
Box16,
|
|
31519
|
+
{
|
|
31520
|
+
"data-testid": EVENT_DETAILS_HEADING_STATUS_TEST_ID,
|
|
31521
|
+
...clickable(onStatusClick, isTinted),
|
|
31522
|
+
sx: { alignItems: "center", color: `${statusColor}.main`, display: "flex", gap: 0.5, minWidth: 0, ...clickable(onStatusClick, isTinted).sx, ...isTinted ? tint(statusColor) : {} },
|
|
31523
|
+
children: [
|
|
31524
|
+
/* @__PURE__ */ jsx142(StatusIcon2, { sx: { color: isTinted ? `${statusColor}.main` : void 0, fontSize: 14 } }),
|
|
31525
|
+
/* @__PURE__ */ jsx142(Typography12, { color: isTinted ? "inherit" : void 0, noWrap: true, variant: "caption", children: isError ? `Failed \xB7 ${statusText}` : "Succeeded" })
|
|
31526
|
+
]
|
|
31527
|
+
}
|
|
31528
|
+
),
|
|
31529
|
+
showStatus && iamStyle && !isTinted && /* @__PURE__ */ jsx142(Typography12, { color: "text.disabled", variant: "caption", children: "|" }),
|
|
31530
|
+
iamStyle && /* @__PURE__ */ jsxs131(
|
|
31531
|
+
Box16,
|
|
31532
|
+
{
|
|
31533
|
+
"data-testid": EVENT_DETAILS_HEADING_IAM_TEST_ID,
|
|
31534
|
+
...clickable(onIamClick, isTinted),
|
|
31535
|
+
sx: { alignItems: "center", color: paletteColor(iamStyle.color), display: "flex", flex: "none", gap: 0.5, ...clickable(onIamClick, isTinted).sx, ...isTinted ? tint(iamStyle.color) : {} },
|
|
31536
|
+
children: [
|
|
31537
|
+
/* @__PURE__ */ jsx142(iamStyle.icon, { sx: { color: isTinted ? paletteColor(iamStyle.color) : void 0, fontSize: 14 } }),
|
|
31538
|
+
/* @__PURE__ */ jsx142(Typography12, { color: isTinted ? "inherit" : void 0, variant: "caption", children: iamLabel })
|
|
31539
|
+
]
|
|
31540
|
+
}
|
|
31541
|
+
)
|
|
31542
|
+
] });
|
|
31543
|
+
};
|
|
31544
|
+
|
|
31405
31545
|
// src/components/event-details/event-details.tsx
|
|
31406
|
-
import { Fragment as Fragment10, jsx as
|
|
31546
|
+
import { Fragment as Fragment10, jsx as jsx143, jsxs as jsxs132 } from "react/jsx-runtime";
|
|
31407
31547
|
var checkIsLambdaInvoke = (span) => {
|
|
31408
31548
|
if (span.service_name !== "lambda") {
|
|
31409
31549
|
return false;
|
|
@@ -31417,14 +31557,17 @@ var checkIsSqsSendMessage = (span) => {
|
|
|
31417
31557
|
}
|
|
31418
31558
|
return span.operation_name.startsWith("SendMessage");
|
|
31419
31559
|
};
|
|
31420
|
-
var
|
|
31421
|
-
|
|
31422
|
-
|
|
31423
|
-
|
|
31424
|
-
|
|
31560
|
+
var PERMISSION_SEVERITY = ["explicitly_denied", "implicitly_denied", "explicitly_allowed"];
|
|
31561
|
+
var getWorstPermission = (events) => PERMISSION_SEVERITY.find((permission) => events.some((event) => event.permission === permission));
|
|
31562
|
+
var IAM_OUTCOME = { allowed: "allowed", error: "denied", none: void 0, warning: "warning" };
|
|
31563
|
+
var Field = ({ children, copy, label, testId, testIdOn = "value" }) => /* @__PURE__ */ jsxs132(Box17, { children: [
|
|
31564
|
+
/* @__PURE__ */ jsx143(Typography13, { sx: { fontWeight: 600 }, variant: "caption", children: label }),
|
|
31565
|
+
/* @__PURE__ */ jsxs132(Stack4, { alignItems: "center", "data-testid": testIdOn === "row" ? testId : void 0, direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
31566
|
+
/* @__PURE__ */ jsx143(Typography13, { "data-testid": testIdOn === "value" ? testId : void 0, variant: "body2", children }),
|
|
31567
|
+
/* @__PURE__ */ jsx143(CopyButton, { value: copy ?? children })
|
|
31425
31568
|
] })
|
|
31426
31569
|
] });
|
|
31427
|
-
var EmptyTab = ({ children }) => /* @__PURE__ */
|
|
31570
|
+
var EmptyTab = ({ children }) => /* @__PURE__ */ jsx143(Typography13, { color: "text.secondary", variant: "body2", children });
|
|
31428
31571
|
var EventDetails = ({ onClose, selectedEvent }) => {
|
|
31429
31572
|
const eventGroups = useMemo10(
|
|
31430
31573
|
() => getEventGroupsByType(selectedEvent?.events ?? []),
|
|
@@ -31432,8 +31575,9 @@ var EventDetails = ({ onClose, selectedEvent }) => {
|
|
|
31432
31575
|
);
|
|
31433
31576
|
const [parseNestedJson, setParseNestedJson] = useState13(true);
|
|
31434
31577
|
const [tab, setTab] = useState13("details");
|
|
31578
|
+
const { operationStatus: variant } = useDevSettings();
|
|
31435
31579
|
if (!selectedEvent) {
|
|
31436
|
-
return /* @__PURE__ */
|
|
31580
|
+
return /* @__PURE__ */ jsx143(Box17, { sx: { p: 3, textAlign: "center" }, children: /* @__PURE__ */ jsx143(Typography13, { color: "text.secondary", variant: "body2", children: "Select an operation to view graph" }) });
|
|
31437
31581
|
}
|
|
31438
31582
|
const isLambdaInvoke = checkIsLambdaInvoke(selectedEvent);
|
|
31439
31583
|
const isSqsSendMessage = checkIsSqsSendMessage(selectedEvent);
|
|
@@ -31459,27 +31603,48 @@ var EventDetails = ({ onClose, selectedEvent }) => {
|
|
|
31459
31603
|
}
|
|
31460
31604
|
}
|
|
31461
31605
|
const exceptionPayload = tryParseJson(selectedEvent.attributes?.["localstack.aws.service.exception"]);
|
|
31606
|
+
const functionError = isLambdaInvoke ? getLambdaFunctionError(selectedEvent.attributes?.["localstack.aws.service.response"]) : void 0;
|
|
31607
|
+
const errorType = functionError?.errorType ?? issues.errorType;
|
|
31462
31608
|
const duration = selectedEvent.end_time_unix_nano ? ((BigInt(selectedEvent.end_time_unix_nano) - BigInt(selectedEvent.start_time_unix_nano)) / BigInt("1000000")).toString() : void 0;
|
|
31463
31609
|
const resource = shortResourceName(selectedEvent.resource_name, selectedEvent.arn);
|
|
31464
31610
|
const showError = issues.error;
|
|
31465
31611
|
const showPermissions = selectedEvent.iam_errors_suppressed === true || eventGroups.permissions !== void 0;
|
|
31466
31612
|
const showLogs = isLambdaInvoke && requestId !== void 0;
|
|
31467
31613
|
const activeTab = tab === "error" && !showError || tab === "permissions" && !showPermissions || tab === "logs" && !showLogs ? "details" : tab;
|
|
31468
|
-
const errorMessages = [.../* @__PURE__ */ new Set([selectedEvent.status_message, ...(selectedEvent.errors ?? []).filter((item) => item.level === "error").map((item) => item.message)])].filter((message) => Boolean(message) && message !==
|
|
31469
|
-
const
|
|
31614
|
+
const errorMessages = functionError?.errorMessage === void 0 ? [.../* @__PURE__ */ new Set([selectedEvent.status_message, ...(selectedEvent.errors ?? []).filter((item) => item.level === "error").map((item) => item.message)])].filter((message) => Boolean(message) && message !== errorType) : [functionError.errorMessage];
|
|
31615
|
+
const iamEvents = getIamEvents(selectedEvent);
|
|
31616
|
+
const iamPermission = getWorstPermission(iamEvents);
|
|
31617
|
+
const iamOutcome = selectedEvent.iam_errors_suppressed === true ? "suppressed" : IAM_OUTCOME[iam.level ?? (iamEvents.length > 0 ? "allowed" : "none")];
|
|
31618
|
+
const statusBadges = /* @__PURE__ */ jsx143(
|
|
31619
|
+
OperationStatusBadges,
|
|
31620
|
+
{
|
|
31621
|
+
iam: iamOutcome,
|
|
31622
|
+
iamPermission,
|
|
31623
|
+
onIamClick: showPermissions ? () => {
|
|
31624
|
+
setTab("permissions");
|
|
31625
|
+
} : void 0,
|
|
31626
|
+
onStatusClick: () => {
|
|
31627
|
+
setTab(showError ? "error" : "response");
|
|
31628
|
+
},
|
|
31629
|
+
status: issues.error ? "error" : selectedEvent.status_code === 1 ? "ok" : "unset",
|
|
31630
|
+
statusLabel: errorType,
|
|
31631
|
+
variant
|
|
31632
|
+
}
|
|
31633
|
+
);
|
|
31634
|
+
const rawDataSwitch = /* @__PURE__ */ jsx143(
|
|
31470
31635
|
FormControlLabel,
|
|
31471
31636
|
{
|
|
31472
|
-
control: /* @__PURE__ */
|
|
31637
|
+
control: /* @__PURE__ */ jsx143(Switch, { checked: !parseNestedJson, onChange: (event) => {
|
|
31473
31638
|
setParseNestedJson(!event.target.checked);
|
|
31474
31639
|
}, size: "small" }),
|
|
31475
|
-
label: /* @__PURE__ */
|
|
31640
|
+
label: /* @__PURE__ */ jsx143(Typography13, { variant: "caption", children: "View raw data" }),
|
|
31476
31641
|
sx: { mb: 1, mr: 0 }
|
|
31477
31642
|
}
|
|
31478
31643
|
);
|
|
31479
|
-
const permissionsIcon = iam.level === "error" ? /* @__PURE__ */
|
|
31480
|
-
return /* @__PURE__ */
|
|
31481
|
-
/* @__PURE__ */
|
|
31482
|
-
|
|
31644
|
+
const permissionsIcon = iam.level === "error" ? /* @__PURE__ */ jsx143(GppBad2, { color: "error", sx: { fontSize: 16 } }) : iam.level === "warning" ? /* @__PURE__ */ jsx143(GppMaybe7, { color: "warning", sx: { fontSize: 16 } }) : void 0;
|
|
31645
|
+
return /* @__PURE__ */ jsxs132(Box17, { "data-testid": EVENT_DETAILS_TEST_ID, sx: { display: "flex", flexDirection: "column", height: "100%" }, children: [
|
|
31646
|
+
/* @__PURE__ */ jsxs132(
|
|
31647
|
+
Box17,
|
|
31483
31648
|
{
|
|
31484
31649
|
sx: {
|
|
31485
31650
|
alignItems: "center",
|
|
@@ -31491,22 +31656,21 @@ var EventDetails = ({ onClose, selectedEvent }) => {
|
|
|
31491
31656
|
py: 1
|
|
31492
31657
|
},
|
|
31493
31658
|
children: [
|
|
31494
|
-
/* @__PURE__ */
|
|
31495
|
-
/* @__PURE__ */
|
|
31496
|
-
/* @__PURE__ */
|
|
31497
|
-
/* @__PURE__ */
|
|
31498
|
-
/* @__PURE__ */
|
|
31499
|
-
|
|
31500
|
-
|
|
31501
|
-
/* @__PURE__ */ jsx142(Typography12, { color: "text.secondary", "data-testid": EVENT_DETAILS_HEADING_DURATION_TEST_ID, sx: { flex: "none", ml: "auto", textAlign: "right", width: 64 }, variant: "body2", children: formatDuration(Number(duration)) })
|
|
31659
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { containerType: "inline-size", flex: 1, minWidth: 0 }, children: [
|
|
31660
|
+
/* @__PURE__ */ jsx143(Typography13, { color: "text.secondary", component: "div", sx: { lineHeight: 1.5 }, variant: "overline", children: "Selected operation" }),
|
|
31661
|
+
/* @__PURE__ */ jsxs132(Box17, { "data-testid": EVENT_DETAILS_HEADING_TEST_ID, sx: { "@container (min-width: 560px)": { flexWrap: "nowrap" }, "alignItems": "center", "columnGap": 1, "display": "flex", "flexWrap": variant.startsWith("subtitle") ? "wrap" : "nowrap", "minWidth": 0 }, children: [
|
|
31662
|
+
/* @__PURE__ */ jsx143(AwsServiceIcon, { hideTooltip: true, service: selectedEvent.service_name, size: "small" }),
|
|
31663
|
+
/* @__PURE__ */ jsx143(Typography13, { noWrap: true, sx: { flex: "0 1 auto", fontWeight: 600, minWidth: 0 }, title: selectedEvent.operation_name, variant: "subtitle1", children: selectedEvent.operation_name }),
|
|
31664
|
+
/* @__PURE__ */ jsx143(Box17, { sx: variant.startsWith("subtitle") ? { "@container (min-width: 560px)": { flexBasis: "auto", order: 0 }, "display": "flex", "flex": "none", "flexBasis": "100%", "order": 1 } : { display: "flex", flex: "none" }, children: statusBadges }),
|
|
31665
|
+
resource !== "" && resource !== "*" && /* @__PURE__ */ jsx143(Typography13, { color: "text.secondary", noWrap: true, sx: { flex: "1 1 0", minWidth: 0 }, title: resource, variant: "body2", children: resource })
|
|
31502
31666
|
] })
|
|
31503
31667
|
] }),
|
|
31504
|
-
onClose && /* @__PURE__ */
|
|
31668
|
+
onClose && /* @__PURE__ */ jsx143(IconButton6, { "data-testid": EVENT_DETAILS_CLOSE_BUTTON_TEST_ID, onClick: onClose, size: "small", children: /* @__PURE__ */ jsx143(Close3, {}) })
|
|
31505
31669
|
]
|
|
31506
31670
|
}
|
|
31507
31671
|
),
|
|
31508
|
-
/* @__PURE__ */
|
|
31509
|
-
/* @__PURE__ */
|
|
31672
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { flexGrow: 1, minHeight: 0, overflow: "auto" }, children: [
|
|
31673
|
+
/* @__PURE__ */ jsxs132(
|
|
31510
31674
|
Tabs,
|
|
31511
31675
|
{
|
|
31512
31676
|
onChange: (_event, value) => {
|
|
@@ -31526,87 +31690,94 @@ var EventDetails = ({ onClose, selectedEvent }) => {
|
|
|
31526
31690
|
value: activeTab,
|
|
31527
31691
|
variant: "scrollable",
|
|
31528
31692
|
children: [
|
|
31529
|
-
/* @__PURE__ */
|
|
31530
|
-
/* @__PURE__ */
|
|
31531
|
-
/* @__PURE__ */
|
|
31532
|
-
showError && /* @__PURE__ */
|
|
31533
|
-
showPermissions && /* @__PURE__ */
|
|
31534
|
-
showLogs && /* @__PURE__ */
|
|
31693
|
+
/* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_DETAILS_TEST_ID, label: "Details", value: "details" }),
|
|
31694
|
+
/* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_REQUEST_TEST_ID, label: "Payload", value: "request" }),
|
|
31695
|
+
/* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_RESPONSE_TEST_ID, label: "Response", value: "response" }),
|
|
31696
|
+
showError && /* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_ERROR_TEST_ID, icon: /* @__PURE__ */ jsx143(Cancel6, { color: "error", sx: { fontSize: 16 } }), iconPosition: "end", label: "Error", value: "error" }),
|
|
31697
|
+
showPermissions && /* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_PERMISSIONS_TEST_ID, icon: permissionsIcon, iconPosition: "end", label: "Permissions", value: "permissions" }),
|
|
31698
|
+
showLogs && /* @__PURE__ */ jsx143(Tab, { "data-testid": DETAIL_TAB_LOGS_TEST_ID, label: "Logs", value: "logs" })
|
|
31535
31699
|
]
|
|
31536
31700
|
}
|
|
31537
31701
|
),
|
|
31538
|
-
/* @__PURE__ */
|
|
31539
|
-
activeTab === "details" && /* @__PURE__ */
|
|
31540
|
-
/* @__PURE__ */
|
|
31541
|
-
/* @__PURE__ */
|
|
31542
|
-
/* @__PURE__ */
|
|
31543
|
-
/* @__PURE__ */
|
|
31702
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { p: 2 }, children: [
|
|
31703
|
+
activeTab === "details" && /* @__PURE__ */ jsxs132(Stack4, { spacing: 2, children: [
|
|
31704
|
+
/* @__PURE__ */ jsxs132(Stack4, { "data-testid": EVENT_DETAILS_SECTION_BASIC_INFORMATION_TEST_ID, spacing: 1, children: [
|
|
31705
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { display: "grid", gap: 2, gridTemplateColumns: "1.3fr 1fr" }, children: [
|
|
31706
|
+
/* @__PURE__ */ jsx143(Field, { copy: getServiceDisplayName(selectedEvent.service_name), label: "Service", testId: EVENT_DETAILS_SERVICE_NAME_TEST_ID, children: getServiceDisplayName(selectedEvent.service_name) }),
|
|
31707
|
+
/* @__PURE__ */ jsx143(Field, { label: "Action", testId: EVENT_DETAILS_OPERATION_NAME_TEST_ID, children: selectedEvent.operation_name })
|
|
31544
31708
|
] }),
|
|
31545
|
-
/* @__PURE__ */
|
|
31546
|
-
/* @__PURE__ */
|
|
31547
|
-
Boolean(cfnResourceType) && /* @__PURE__ */
|
|
31709
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: cfnResourceType ? { display: "grid", gap: 2, gridTemplateColumns: "1.3fr 1fr" } : void 0, children: [
|
|
31710
|
+
/* @__PURE__ */ jsx143(Field, { label: "Resource", testId: EVENT_DETAILS_RESOURCE_NAME_TEST_ID, testIdOn: "row", children: selectedEvent.resource_name }),
|
|
31711
|
+
Boolean(cfnResourceType) && /* @__PURE__ */ jsx143(Field, { label: "Resource Type", testId: EVENT_DETAILS_CFN_RESOURCE_TYPE_TEST_ID, children: cfnResourceType })
|
|
31548
31712
|
] }),
|
|
31549
|
-
Boolean(resourceArn) && /* @__PURE__ */
|
|
31550
|
-
/* @__PURE__ */
|
|
31551
|
-
/* @__PURE__ */
|
|
31552
|
-
/* @__PURE__ */
|
|
31713
|
+
Boolean(resourceArn) && /* @__PURE__ */ jsx143(Field, { label: "Resource ARN", testId: EVENT_DETAILS_RESOURCE_ARN_TEST_ID, testIdOn: "row", children: resourceArn }),
|
|
31714
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { display: "grid", gap: 1, gridTemplateColumns: "1.3fr 1fr" }, children: [
|
|
31715
|
+
/* @__PURE__ */ jsx143(Field, { label: "Account", testId: EVENT_DETAILS_ACCOUNT_TEST_ID, children: selectedEvent.account_id }),
|
|
31716
|
+
/* @__PURE__ */ jsx143(Field, { label: "Region", testId: EVENT_DETAILS_REGION_TEST_ID, children: selectedEvent.region })
|
|
31553
31717
|
] }),
|
|
31554
|
-
/* @__PURE__ */
|
|
31555
|
-
/* @__PURE__ */
|
|
31718
|
+
/* @__PURE__ */ jsxs132(Box17, { sx: { display: "grid", gap: 1, gridTemplateColumns: duration === void 0 ? "1fr" : "1.3fr 1fr" }, children: [
|
|
31719
|
+
/* @__PURE__ */ jsx143(
|
|
31556
31720
|
Field,
|
|
31557
31721
|
{
|
|
31558
31722
|
copy: unixNanoToDate(selectedEvent.start_time_unix_nano)?.toISOString(),
|
|
31559
31723
|
label: "Start Time",
|
|
31560
31724
|
testId: EVENT_DETAILS_START_TIME_TEST_ID,
|
|
31561
31725
|
testIdOn: "row",
|
|
31562
|
-
children: /* @__PURE__ */
|
|
31726
|
+
children: /* @__PURE__ */ jsx143(ResponsiveTimestampCell, { date: unixNanoToDate(selectedEvent.start_time_unix_nano) })
|
|
31563
31727
|
}
|
|
31564
31728
|
),
|
|
31565
|
-
duration !== void 0 && /* @__PURE__ */
|
|
31729
|
+
duration !== void 0 && /* @__PURE__ */ jsxs132(Field, { copy: `${duration}ms`, label: "Duration", testId: EVENT_DETAILS_DURATION_TEST_ID, testIdOn: "row", children: [
|
|
31566
31730
|
duration,
|
|
31567
31731
|
"ms"
|
|
31568
31732
|
] })
|
|
31569
|
-
] }),
|
|
31570
|
-
/* @__PURE__ */ jsxs131(Box16, { children: [
|
|
31571
|
-
/* @__PURE__ */ jsx142(Typography12, { sx: { fontWeight: 600 }, variant: "caption", children: "Status" }),
|
|
31572
|
-
/* @__PURE__ */ jsx142(Stack4, { alignItems: "center", direction: "row", flexWrap: "wrap", gap: 1, sx: { mb: eventGroups.errors || eventGroups.warnings ? 1 : 0 }, children: /* @__PURE__ */ jsx142(
|
|
31573
|
-
Chip3,
|
|
31574
|
-
{
|
|
31575
|
-
color: selectedEvent.status_code === 2 ? "error" : selectedEvent.status_code === 1 ? "success" : "default",
|
|
31576
|
-
"data-testid": EVENT_DETAILS_STATUS_TEST_ID,
|
|
31577
|
-
label: selectedEvent.status_code === 2 ? "Error" : selectedEvent.status_code === 1 ? "OK" : "Unset",
|
|
31578
|
-
size: "small"
|
|
31579
|
-
}
|
|
31580
|
-
) })
|
|
31581
31733
|
] })
|
|
31582
31734
|
] }),
|
|
31583
|
-
eventGroups.errors && /* @__PURE__ */
|
|
31584
|
-
eventGroups.warnings && /* @__PURE__ */
|
|
31585
|
-
eventGroups.info && /* @__PURE__ */
|
|
31735
|
+
eventGroups.errors && /* @__PURE__ */ jsx143(EventDetail, { displayText: "Error", events: eventGroups.errors, type: "error" }),
|
|
31736
|
+
eventGroups.warnings && /* @__PURE__ */ jsx143(EventDetail, { displayText: "Warning", events: eventGroups.warnings, type: "warning" }),
|
|
31737
|
+
eventGroups.info && /* @__PURE__ */ jsx143(EventDetail, { displayText: "Info", events: eventGroups.info, type: "info" })
|
|
31586
31738
|
] }),
|
|
31587
|
-
activeTab === "request" && (requestPayload === void 0 ? /* @__PURE__ */
|
|
31739
|
+
activeTab === "request" && (requestPayload === void 0 ? /* @__PURE__ */ jsx143(EmptyTab, { children: "No request payload recorded." }) : /* @__PURE__ */ jsxs132(Fragment10, { children: [
|
|
31588
31740
|
rawDataSwitch,
|
|
31589
|
-
/* @__PURE__ */
|
|
31741
|
+
/* @__PURE__ */ jsx143(PayloadViewer, { testId: EVENT_DETAILS_REQUEST_PAYLOAD, value: requestPayload })
|
|
31590
31742
|
] })),
|
|
31591
|
-
activeTab === "response" && (responsePayload === void 0 && !isResponseSuppressed ? /* @__PURE__ */
|
|
31743
|
+
activeTab === "response" && (responsePayload === void 0 && !isResponseSuppressed ? /* @__PURE__ */ jsx143(EmptyTab, { children: issues.error ? "No response: the call failed. See the Error tab." : "No response payload recorded." }) : /* @__PURE__ */ jsxs132(Fragment10, { children: [
|
|
31592
31744
|
rawDataSwitch,
|
|
31593
|
-
isResponseSuppressed ? /* @__PURE__ */
|
|
31745
|
+
isResponseSuppressed ? /* @__PURE__ */ jsx143(Alert4, { severity: "warning", children: "Response payload is available \u2014 upgrade your license to view" }) : /* @__PURE__ */ jsx143(PayloadViewer, { testId: EVENT_DETAILS_RESPONSE_PAYLOAD_TEST_ID, value: responsePayload })
|
|
31594
31746
|
] })),
|
|
31595
|
-
activeTab === "error" && /* @__PURE__ */
|
|
31596
|
-
/* @__PURE__ */
|
|
31597
|
-
/* @__PURE__ */
|
|
31598
|
-
errorMessages.length > 0 && /* @__PURE__ */
|
|
31747
|
+
activeTab === "error" && /* @__PURE__ */ jsxs132(Stack4, { spacing: 2, children: [
|
|
31748
|
+
/* @__PURE__ */ jsxs132(Stack4, { spacing: 1, children: [
|
|
31749
|
+
/* @__PURE__ */ jsx143(Field, { label: "Type", children: errorType }),
|
|
31750
|
+
errorMessages.length > 0 && /* @__PURE__ */ jsx143(Field, { label: "Message", children: errorMessages.join(" \xB7 ") }),
|
|
31751
|
+
functionError && /* @__PURE__ */ jsxs132(Box17, { sx: { display: "grid", gap: 2, gridTemplateColumns: "1.3fr 1fr" }, children: [
|
|
31752
|
+
functionError.requestId !== void 0 && /* @__PURE__ */ jsx143(Field, { label: "Request ID", children: functionError.requestId }),
|
|
31753
|
+
/* @__PURE__ */ jsx143(Field, { label: "Function Error", testId: EVENT_DETAILS_FUNCTION_ERROR_TEST_ID, children: functionError.functionError })
|
|
31754
|
+
] })
|
|
31755
|
+
] }),
|
|
31756
|
+
functionError?.stackTrace !== void 0 && /* @__PURE__ */ jsxs132(Box17, { children: [
|
|
31757
|
+
/* @__PURE__ */ jsxs132(Stack4, { alignItems: "center", direction: "row", sx: { "&:hover .copy-btn": { opacity: 1 } }, children: [
|
|
31758
|
+
/* @__PURE__ */ jsx143(Typography13, { sx: { fontWeight: 600 }, variant: "caption", children: "Stack Trace" }),
|
|
31759
|
+
/* @__PURE__ */ jsx143(CopyButton, { value: functionError.stackTrace })
|
|
31760
|
+
] }),
|
|
31761
|
+
/* @__PURE__ */ jsx143(
|
|
31762
|
+
Box17,
|
|
31763
|
+
{
|
|
31764
|
+
component: "pre",
|
|
31765
|
+
"data-testid": EVENT_DETAILS_STACK_TRACE_TEST_ID,
|
|
31766
|
+
sx: { backgroundColor: "background.default", borderRadius: 1, fontFamily: "monospace", fontSize: 12, m: 0, overflow: "auto", p: 1 },
|
|
31767
|
+
children: functionError.stackTrace
|
|
31768
|
+
}
|
|
31769
|
+
)
|
|
31599
31770
|
] }),
|
|
31600
|
-
exceptionPayload !== void 0 && /* @__PURE__ */
|
|
31601
|
-
/* @__PURE__ */
|
|
31602
|
-
/* @__PURE__ */
|
|
31771
|
+
exceptionPayload !== void 0 && /* @__PURE__ */ jsxs132(Box17, { children: [
|
|
31772
|
+
/* @__PURE__ */ jsx143(Typography13, { sx: { fontWeight: 600, mb: 0.5 }, variant: "caption", children: "Exception" }),
|
|
31773
|
+
/* @__PURE__ */ jsx143(PayloadViewer, { testId: EVENT_DETAILS_EXCEPTION_PAYLOAD_TEST_ID, value: exceptionPayload })
|
|
31603
31774
|
] })
|
|
31604
31775
|
] }),
|
|
31605
|
-
activeTab === "permissions" && /* @__PURE__ */
|
|
31606
|
-
selectedEvent.iam_errors_suppressed && /* @__PURE__ */
|
|
31607
|
-
eventGroups.permissions && /* @__PURE__ */
|
|
31776
|
+
activeTab === "permissions" && /* @__PURE__ */ jsxs132(Fragment10, { children: [
|
|
31777
|
+
selectedEvent.iam_errors_suppressed && /* @__PURE__ */ jsx143(Alert4, { "data-testid": EVENT_DETAILS_IAM_ERRORS_SUPPRESSED_TEST_ID, severity: "warning", sx: { mb: 1 }, children: "IAM errors are suppressed \u2014 upgrade your license to view" }),
|
|
31778
|
+
eventGroups.permissions && /* @__PURE__ */ jsx143(EventDetail, { displayText: "Permissions", events: eventGroups.permissions, type: "permission" })
|
|
31608
31779
|
] }),
|
|
31609
|
-
activeTab === "logs" && requestId !== void 0 && /* @__PURE__ */
|
|
31780
|
+
activeTab === "logs" && requestId !== void 0 && /* @__PURE__ */ jsx143(
|
|
31610
31781
|
LambdaInvokeLogsSection,
|
|
31611
31782
|
{
|
|
31612
31783
|
endTimeNano: selectedEvent.end_time_unix_nano ?? selectedEvent.start_time_unix_nano,
|
|
@@ -31628,13 +31799,13 @@ import { Background, MarkerType, MiniMap, Position as Position2, ReactFlow, useE
|
|
|
31628
31799
|
import { useCallback as useCallback7, useEffect as useEffect16, useRef as useRef13, useState as useState15 } from "react";
|
|
31629
31800
|
|
|
31630
31801
|
// src/components/trace-graph/service-node.tsx
|
|
31631
|
-
import { Cancel as
|
|
31632
|
-
import { Box as
|
|
31802
|
+
import { Cancel as Cancel7, GppMaybe as GppMaybe8 } from "@mui/icons-material";
|
|
31803
|
+
import { Box as Box18, Divider as Divider4, Stack as Stack5, Tooltip as Tooltip7, Typography as Typography14, useTheme as useTheme4 } from "@mui/material";
|
|
31633
31804
|
import { Handle, Position } from "@xyflow/react";
|
|
31634
31805
|
import "@xyflow/react/dist/style.css";
|
|
31635
31806
|
import "react";
|
|
31636
31807
|
import { memo as memo11, useRef as useRef12, useState as useState14 } from "react";
|
|
31637
|
-
import { Fragment as Fragment11, jsx as
|
|
31808
|
+
import { Fragment as Fragment11, jsx as jsx144, jsxs as jsxs133 } from "react/jsx-runtime";
|
|
31638
31809
|
var handleStyle = {
|
|
31639
31810
|
backgroundColor: "white",
|
|
31640
31811
|
borderColor: "lightgray",
|
|
@@ -31642,20 +31813,20 @@ var handleStyle = {
|
|
|
31642
31813
|
};
|
|
31643
31814
|
var NodeContent = ({ event, expanded, issues }) => {
|
|
31644
31815
|
const theme = useTheme4();
|
|
31645
|
-
return /* @__PURE__ */
|
|
31646
|
-
/* @__PURE__ */
|
|
31647
|
-
/* @__PURE__ */
|
|
31648
|
-
/* @__PURE__ */
|
|
31816
|
+
return /* @__PURE__ */ jsxs133(Fragment11, { children: [
|
|
31817
|
+
/* @__PURE__ */ jsx144(Handle, { position: Position.Left, style: handleStyle, type: "target" }),
|
|
31818
|
+
/* @__PURE__ */ jsx144(Handle, { position: Position.Right, style: handleStyle, type: "source" }),
|
|
31819
|
+
/* @__PURE__ */ jsxs133(
|
|
31649
31820
|
Stack5,
|
|
31650
31821
|
{
|
|
31651
31822
|
alignItems: "center",
|
|
31652
31823
|
direction: "row",
|
|
31653
31824
|
sx: { gap: "8px", pb: "2px", pt: "6px", px: "8px" },
|
|
31654
31825
|
children: [
|
|
31655
|
-
/* @__PURE__ */
|
|
31656
|
-
/* @__PURE__ */
|
|
31657
|
-
/* @__PURE__ */
|
|
31658
|
-
|
|
31826
|
+
/* @__PURE__ */ jsx144(Box18, { sx: { borderRadius: "4px", flexShrink: 0, lineHeight: 0, overflow: "hidden" }, children: /* @__PURE__ */ jsx144(AwsServiceIcon, { hideTooltip: true, service: event.service_name, size: "medium" }) }),
|
|
31827
|
+
/* @__PURE__ */ jsxs133(Stack5, { sx: expanded ? void 0 : { minWidth: 0 }, children: [
|
|
31828
|
+
/* @__PURE__ */ jsx144(
|
|
31829
|
+
Typography14,
|
|
31659
31830
|
{
|
|
31660
31831
|
noWrap: !expanded,
|
|
31661
31832
|
sx: { fontWeight: 700, lineHeight: 1.25, ...expanded && { whiteSpace: "nowrap" } },
|
|
@@ -31663,8 +31834,8 @@ var NodeContent = ({ event, expanded, issues }) => {
|
|
|
31663
31834
|
children: getServiceDisplayName(event.service_name)
|
|
31664
31835
|
}
|
|
31665
31836
|
),
|
|
31666
|
-
event.resource_name != "" && /* @__PURE__ */
|
|
31667
|
-
|
|
31837
|
+
event.resource_name != "" && /* @__PURE__ */ jsx144(
|
|
31838
|
+
Typography14,
|
|
31668
31839
|
{
|
|
31669
31840
|
color: "text.secondary",
|
|
31670
31841
|
noWrap: !expanded,
|
|
@@ -31677,16 +31848,16 @@ var NodeContent = ({ event, expanded, issues }) => {
|
|
|
31677
31848
|
]
|
|
31678
31849
|
}
|
|
31679
31850
|
),
|
|
31680
|
-
/* @__PURE__ */
|
|
31681
|
-
/* @__PURE__ */
|
|
31851
|
+
/* @__PURE__ */ jsx144(Divider4, { sx: { ml: "38px", mr: "8px", my: "5px" } }),
|
|
31852
|
+
/* @__PURE__ */ jsxs133(
|
|
31682
31853
|
Stack5,
|
|
31683
31854
|
{
|
|
31684
31855
|
alignItems: "center",
|
|
31685
31856
|
direction: "row",
|
|
31686
31857
|
sx: expanded ? { pb: "5px", pr: "8px", pt: "1px" } : { minWidth: 0, pb: "5px", pr: "8px", pt: "1px" },
|
|
31687
31858
|
children: [
|
|
31688
|
-
/* @__PURE__ */
|
|
31689
|
-
|
|
31859
|
+
/* @__PURE__ */ jsxs133(
|
|
31860
|
+
Box18,
|
|
31690
31861
|
{
|
|
31691
31862
|
sx: {
|
|
31692
31863
|
alignItems: "center",
|
|
@@ -31696,13 +31867,13 @@ var NodeContent = ({ event, expanded, issues }) => {
|
|
|
31696
31867
|
width: "38px"
|
|
31697
31868
|
},
|
|
31698
31869
|
children: [
|
|
31699
|
-
issues.error && /* @__PURE__ */
|
|
31700
|
-
issues.warning && /* @__PURE__ */
|
|
31870
|
+
issues.error && /* @__PURE__ */ jsx144(Tooltip7, { arrow: true, title: issues.errorType, children: /* @__PURE__ */ jsx144(Box18, { "aria-label": "Error", role: "img", sx: { display: "flex" }, children: /* @__PURE__ */ jsx144(Cancel7, { sx: { color: theme.palette.error.main, fontSize: "16px" } }) }) }),
|
|
31871
|
+
issues.warning && /* @__PURE__ */ jsx144(Tooltip7, { arrow: true, title: issues.warningType, children: /* @__PURE__ */ jsx144(Box18, { "aria-label": "Warning", role: "img", sx: { display: "flex" }, children: /* @__PURE__ */ jsx144(GppMaybe8, { sx: { color: theme.palette.warning.main, fontSize: "16px" } }) }) })
|
|
31701
31872
|
]
|
|
31702
31873
|
}
|
|
31703
31874
|
),
|
|
31704
|
-
/* @__PURE__ */
|
|
31705
|
-
|
|
31875
|
+
/* @__PURE__ */ jsx144(
|
|
31876
|
+
Typography14,
|
|
31706
31877
|
{
|
|
31707
31878
|
"data-testid": SERVICE_NODE_OPERATION_NAME_TEST_ID,
|
|
31708
31879
|
noWrap: !expanded,
|
|
@@ -31747,8 +31918,8 @@ var ServiceNode = memo11(({ data, selected }) => {
|
|
|
31747
31918
|
const xyNode = nodeRef.current?.closest(".react-flow__node");
|
|
31748
31919
|
if (xyNode) xyNode.style.zIndex = "";
|
|
31749
31920
|
};
|
|
31750
|
-
return /* @__PURE__ */
|
|
31751
|
-
|
|
31921
|
+
return /* @__PURE__ */ jsxs133(
|
|
31922
|
+
Box18,
|
|
31752
31923
|
{
|
|
31753
31924
|
"data-testid": SERVICE_NODE_TEST_ID,
|
|
31754
31925
|
onMouseEnter: handleMouseEnter,
|
|
@@ -31758,8 +31929,8 @@ var ServiceNode = memo11(({ data, selected }) => {
|
|
|
31758
31929
|
sx: { display: "inline-block", position: "relative" },
|
|
31759
31930
|
tabIndex: 0,
|
|
31760
31931
|
children: [
|
|
31761
|
-
/* @__PURE__ */
|
|
31762
|
-
|
|
31932
|
+
/* @__PURE__ */ jsx144(
|
|
31933
|
+
Box18,
|
|
31763
31934
|
{
|
|
31764
31935
|
sx: {
|
|
31765
31936
|
...sharedBoxSx,
|
|
@@ -31767,11 +31938,11 @@ var ServiceNode = memo11(({ data, selected }) => {
|
|
|
31767
31938
|
maxWidth: 220,
|
|
31768
31939
|
overflow: "hidden"
|
|
31769
31940
|
},
|
|
31770
|
-
children: /* @__PURE__ */
|
|
31941
|
+
children: /* @__PURE__ */ jsx144(NodeContent, { ...contentProps, expanded: false })
|
|
31771
31942
|
}
|
|
31772
31943
|
),
|
|
31773
|
-
/* @__PURE__ */
|
|
31774
|
-
|
|
31944
|
+
/* @__PURE__ */ jsx144(
|
|
31945
|
+
Box18,
|
|
31775
31946
|
{
|
|
31776
31947
|
onMouseLeave: handleMouseLeave,
|
|
31777
31948
|
sx: {
|
|
@@ -31785,7 +31956,7 @@ var ServiceNode = memo11(({ data, selected }) => {
|
|
|
31785
31956
|
width: "max-content",
|
|
31786
31957
|
zIndex: 10
|
|
31787
31958
|
},
|
|
31788
|
-
children: /* @__PURE__ */
|
|
31959
|
+
children: /* @__PURE__ */ jsx144(NodeContent, { ...contentProps, expanded: true })
|
|
31789
31960
|
}
|
|
31790
31961
|
)
|
|
31791
31962
|
]
|
|
@@ -31880,11 +32051,11 @@ var getLayoutedNodesAndEdges = (inputNodes, inputEdges) => {
|
|
|
31880
32051
|
|
|
31881
32052
|
// src/components/trace-graph/xyflow/controls.tsx
|
|
31882
32053
|
import { Add, FitScreen, Remove } from "@mui/icons-material";
|
|
31883
|
-
import { Box as
|
|
32054
|
+
import { Box as Box19, IconButton as IconButton7 } from "@mui/material";
|
|
31884
32055
|
import { useReactFlow, useStore as useStore2 } from "@xyflow/react";
|
|
31885
32056
|
import { memo as memo12 } from "react";
|
|
31886
32057
|
import { shallow } from "zustand/shallow";
|
|
31887
|
-
import { jsx as
|
|
32058
|
+
import { jsx as jsx145, jsxs as jsxs134 } from "react/jsx-runtime";
|
|
31888
32059
|
var selector = (s) => ({
|
|
31889
32060
|
isInteractive: s.nodesDraggable || s.nodesConnectable || s.elementsSelectable,
|
|
31890
32061
|
maxZoomReached: s.transform[2] >= s.maxZoom,
|
|
@@ -31902,8 +32073,8 @@ var Controls = memo12(() => {
|
|
|
31902
32073
|
const onFitViewHandler = () => {
|
|
31903
32074
|
void fitView();
|
|
31904
32075
|
};
|
|
31905
|
-
return /* @__PURE__ */
|
|
31906
|
-
|
|
32076
|
+
return /* @__PURE__ */ jsxs134(
|
|
32077
|
+
Box19,
|
|
31907
32078
|
{
|
|
31908
32079
|
sx: {
|
|
31909
32080
|
bottom: 0,
|
|
@@ -31916,33 +32087,33 @@ var Controls = memo12(() => {
|
|
|
31916
32087
|
zIndex: 5
|
|
31917
32088
|
},
|
|
31918
32089
|
children: [
|
|
31919
|
-
/* @__PURE__ */
|
|
32090
|
+
/* @__PURE__ */ jsx145(
|
|
31920
32091
|
IconButton7,
|
|
31921
32092
|
{
|
|
31922
32093
|
className: "react-flow__controls-zoomin",
|
|
31923
32094
|
disabled: maxZoomReached,
|
|
31924
32095
|
onClick: onZoomInHandler,
|
|
31925
32096
|
size: "small",
|
|
31926
|
-
children: /* @__PURE__ */
|
|
32097
|
+
children: /* @__PURE__ */ jsx145(Add, {})
|
|
31927
32098
|
}
|
|
31928
32099
|
),
|
|
31929
|
-
/* @__PURE__ */
|
|
32100
|
+
/* @__PURE__ */ jsx145(
|
|
31930
32101
|
IconButton7,
|
|
31931
32102
|
{
|
|
31932
32103
|
className: "react-flow__controls-zoomout",
|
|
31933
32104
|
disabled: minZoomReached,
|
|
31934
32105
|
onClick: onZoomOutHandler,
|
|
31935
32106
|
size: "small",
|
|
31936
|
-
children: /* @__PURE__ */
|
|
32107
|
+
children: /* @__PURE__ */ jsx145(Remove, {})
|
|
31937
32108
|
}
|
|
31938
32109
|
),
|
|
31939
|
-
/* @__PURE__ */
|
|
32110
|
+
/* @__PURE__ */ jsx145(
|
|
31940
32111
|
IconButton7,
|
|
31941
32112
|
{
|
|
31942
32113
|
className: "react-flow__controls-fitview",
|
|
31943
32114
|
onClick: onFitViewHandler,
|
|
31944
32115
|
size: "small",
|
|
31945
|
-
children: /* @__PURE__ */
|
|
32116
|
+
children: /* @__PURE__ */ jsx145(FitScreen, {})
|
|
31946
32117
|
}
|
|
31947
32118
|
)
|
|
31948
32119
|
]
|
|
@@ -31954,7 +32125,7 @@ var Controls = memo12(() => {
|
|
|
31954
32125
|
import { useTheme as useTheme5 } from "@mui/material";
|
|
31955
32126
|
import { useStore as useStore3 } from "@xyflow/react";
|
|
31956
32127
|
import { memo as memo13 } from "react";
|
|
31957
|
-
import { jsx as
|
|
32128
|
+
import { jsx as jsx146, jsxs as jsxs135 } from "react/jsx-runtime";
|
|
31958
32129
|
var ICON_FRACTION = 0.35;
|
|
31959
32130
|
var PADDING_FRACTION = 0.18;
|
|
31960
32131
|
var ICON_NATIVE_SIZE = 80;
|
|
@@ -31983,10 +32154,10 @@ var MinimapServiceNode = memo13(({
|
|
|
31983
32154
|
const dotY = y + height - padding - dotRadius;
|
|
31984
32155
|
const outlineColor = selected ? isError ? errorColor : "#1a73e8" : "#cccccc";
|
|
31985
32156
|
const outlineWidth = selected ? 2 : 1;
|
|
31986
|
-
return /* @__PURE__ */
|
|
32157
|
+
return /* @__PURE__ */ jsxs135("g", { onClick: onClick ? (event2) => {
|
|
31987
32158
|
onClick(event2, id2);
|
|
31988
32159
|
} : void 0, children: [
|
|
31989
|
-
/* @__PURE__ */
|
|
32160
|
+
/* @__PURE__ */ jsx146(
|
|
31990
32161
|
"rect",
|
|
31991
32162
|
{
|
|
31992
32163
|
fill: theme.palette.background.paper,
|
|
@@ -32000,7 +32171,7 @@ var MinimapServiceNode = memo13(({
|
|
|
32000
32171
|
y
|
|
32001
32172
|
}
|
|
32002
32173
|
),
|
|
32003
|
-
isError && /* @__PURE__ */
|
|
32174
|
+
isError && /* @__PURE__ */ jsx146(
|
|
32004
32175
|
"rect",
|
|
32005
32176
|
{
|
|
32006
32177
|
fill: errorColor,
|
|
@@ -32012,8 +32183,8 @@ var MinimapServiceNode = memo13(({
|
|
|
32012
32183
|
y: y + 3
|
|
32013
32184
|
}
|
|
32014
32185
|
),
|
|
32015
|
-
Icon && /* @__PURE__ */
|
|
32016
|
-
isError && Icon && /* @__PURE__ */
|
|
32186
|
+
Icon && /* @__PURE__ */ jsx146("g", { transform: `translate(${String(x + padding)}, ${String(y + padding)}) scale(${String(scale2)})`, children: /* @__PURE__ */ jsx146(Icon, { height: ICON_NATIVE_SIZE, width: ICON_NATIVE_SIZE }) }),
|
|
32187
|
+
isError && Icon && /* @__PURE__ */ jsx146(
|
|
32017
32188
|
"circle",
|
|
32018
32189
|
{
|
|
32019
32190
|
cx: dotX,
|
|
@@ -32026,7 +32197,7 @@ var MinimapServiceNode = memo13(({
|
|
|
32026
32197
|
});
|
|
32027
32198
|
|
|
32028
32199
|
// src/components/trace-graph/trace-graph.tsx
|
|
32029
|
-
import { Fragment as Fragment12, jsx as
|
|
32200
|
+
import { Fragment as Fragment12, jsx as jsx147, jsxs as jsxs136 } from "react/jsx-runtime";
|
|
32030
32201
|
var nodeTypes = {
|
|
32031
32202
|
service: ServiceNode
|
|
32032
32203
|
};
|
|
@@ -32138,11 +32309,11 @@ var TraceGraph = ({
|
|
|
32138
32309
|
}
|
|
32139
32310
|
}, [spans.data, initialFocusEventId, setNodes, setEdges, updateExtent]);
|
|
32140
32311
|
const theme = useTheme6();
|
|
32141
|
-
return /* @__PURE__ */
|
|
32142
|
-
spans.error && /* @__PURE__ */
|
|
32312
|
+
return /* @__PURE__ */ jsxs136(Fragment12, { children: [
|
|
32313
|
+
spans.error && /* @__PURE__ */ jsxs136(
|
|
32143
32314
|
Alert5,
|
|
32144
32315
|
{
|
|
32145
|
-
action: /* @__PURE__ */
|
|
32316
|
+
action: /* @__PURE__ */ jsx147(Button6, { onClick: () => {
|
|
32146
32317
|
onRefresh();
|
|
32147
32318
|
}, children: "Retry" }),
|
|
32148
32319
|
severity: "error",
|
|
@@ -32154,7 +32325,7 @@ var TraceGraph = ({
|
|
|
32154
32325
|
]
|
|
32155
32326
|
}
|
|
32156
32327
|
),
|
|
32157
|
-
/* @__PURE__ */
|
|
32328
|
+
/* @__PURE__ */ jsxs136(
|
|
32158
32329
|
ReactFlow,
|
|
32159
32330
|
{
|
|
32160
32331
|
colorMode: theme.palette.mode,
|
|
@@ -32174,9 +32345,9 @@ var TraceGraph = ({
|
|
|
32174
32345
|
selectNodesOnDrag: false,
|
|
32175
32346
|
translateExtent,
|
|
32176
32347
|
children: [
|
|
32177
|
-
/* @__PURE__ */
|
|
32178
|
-
/* @__PURE__ */
|
|
32179
|
-
!hideMiniMap && /* @__PURE__ */
|
|
32348
|
+
/* @__PURE__ */ jsx147(ExtentUpdater, { onUpdate: updateExtent, viewportRef }),
|
|
32349
|
+
/* @__PURE__ */ jsx147(Controls, {}),
|
|
32350
|
+
!hideMiniMap && /* @__PURE__ */ jsx147(
|
|
32180
32351
|
MiniMap,
|
|
32181
32352
|
{
|
|
32182
32353
|
nodeComponent: MinimapServiceNode,
|
|
@@ -32184,7 +32355,7 @@ var TraceGraph = ({
|
|
|
32184
32355
|
zoomable: true
|
|
32185
32356
|
}
|
|
32186
32357
|
),
|
|
32187
|
-
/* @__PURE__ */
|
|
32358
|
+
/* @__PURE__ */ jsx147(
|
|
32188
32359
|
Background,
|
|
32189
32360
|
{
|
|
32190
32361
|
bgColor: theme.palette.background.default,
|
|
@@ -32243,9 +32414,9 @@ function useLocalStorage(key, initialValue) {
|
|
|
32243
32414
|
}
|
|
32244
32415
|
|
|
32245
32416
|
// src/components/trace-panel/waterfall.tsx
|
|
32246
|
-
import { AccountTreeOutlined, Cancel as
|
|
32247
|
-
import { Box as
|
|
32248
|
-
import { alpha as
|
|
32417
|
+
import { AccountTreeOutlined, Cancel as Cancel8, FormatListBulleted, GppMaybe as GppMaybe9, KeyboardArrowDown as KeyboardArrowDown2, KeyboardArrowRight as KeyboardArrowRight2 } from "@mui/icons-material";
|
|
32418
|
+
import { Box as Box20, ButtonBase as ButtonBase2, ToggleButton as ToggleButton2, ToggleButtonGroup as ToggleButtonGroup2, Typography as Typography15 } from "@mui/material";
|
|
32419
|
+
import { alpha as alpha6 } from "@mui/material/styles";
|
|
32249
32420
|
import * as React124 from "react";
|
|
32250
32421
|
|
|
32251
32422
|
// src/components/trace-panel/axis-ticks.ts
|
|
@@ -32261,7 +32432,7 @@ var getAxisTicks = (durationMs, maxIntervals) => {
|
|
|
32261
32432
|
var MIN_TICK_SPACING_PX = 56;
|
|
32262
32433
|
var LABEL_GAP_PX = 8;
|
|
32263
32434
|
var CHAR_WIDTH_PX = 6;
|
|
32264
|
-
var estimateWidth = (
|
|
32435
|
+
var estimateWidth = (text3) => text3.length * CHAR_WIDTH_PX;
|
|
32265
32436
|
var layoutAxis = (durationMs, width) => {
|
|
32266
32437
|
if (width <= 0) return { labels: [], marks: [] };
|
|
32267
32438
|
const start = { align: "start", text: formatDuration(0), x: 0 };
|
|
@@ -32276,10 +32447,10 @@ var layoutAxis = (durationMs, width) => {
|
|
|
32276
32447
|
if (tick <= 0 || tick >= durationMs) continue;
|
|
32277
32448
|
const x = tick / durationMs * width;
|
|
32278
32449
|
marks.push(x);
|
|
32279
|
-
const
|
|
32280
|
-
const half = estimateWidth(
|
|
32450
|
+
const text3 = formatDuration(tick);
|
|
32451
|
+
const half = estimateWidth(text3) / 2;
|
|
32281
32452
|
if (x - half >= previousRight + LABEL_GAP_PX && x + half <= endLeft) {
|
|
32282
|
-
labels.push({ align: "center", text:
|
|
32453
|
+
labels.push({ align: "center", text: text3, x });
|
|
32283
32454
|
previousRight = x + half;
|
|
32284
32455
|
}
|
|
32285
32456
|
}
|
|
@@ -32287,7 +32458,7 @@ var layoutAxis = (durationMs, width) => {
|
|
|
32287
32458
|
};
|
|
32288
32459
|
|
|
32289
32460
|
// src/components/trace-panel/waterfall.tsx
|
|
32290
|
-
import { Fragment as Fragment13, jsx as
|
|
32461
|
+
import { Fragment as Fragment13, jsx as jsx148, jsxs as jsxs137 } from "react/jsx-runtime";
|
|
32291
32462
|
var SERVICE_COLORS = {
|
|
32292
32463
|
apigateway: "#7048E8",
|
|
32293
32464
|
dynamodb: "#3B5BDB",
|
|
@@ -32325,12 +32496,12 @@ var flatten = (nodes2, collapsed, depth = 0, branches = [], parent) => nodes2.fl
|
|
|
32325
32496
|
];
|
|
32326
32497
|
});
|
|
32327
32498
|
var flattenAll = (nodes2) => flatten(nodes2, /* @__PURE__ */ new Set()).map((row) => ({ ...row, branches: [], depth: 0, last: true })).toSorted((left, right) => compareNano(left.node.span.start_time_unix_nano, right.node.span.start_time_unix_nano));
|
|
32328
|
-
var StatusIcons = ({ error, warning: warning2 }) => /* @__PURE__ */
|
|
32329
|
-
error && /* @__PURE__ */
|
|
32330
|
-
warning2 && /* @__PURE__ */
|
|
32499
|
+
var StatusIcons = ({ error, warning: warning2 }) => /* @__PURE__ */ jsxs137(Fragment13, { children: [
|
|
32500
|
+
error && /* @__PURE__ */ jsx148(Cancel8, { sx: { color: "error.main", fontSize: 14 } }),
|
|
32501
|
+
warning2 && /* @__PURE__ */ jsx148(GppMaybe9, { sx: { color: "warning.main", fontSize: 14 } })
|
|
32331
32502
|
] });
|
|
32332
|
-
var Line = ({ height, left, top = 0, width = 1 }) => /* @__PURE__ */
|
|
32333
|
-
|
|
32503
|
+
var Line = ({ height, left, top = 0, width = 1 }) => /* @__PURE__ */ jsx148(
|
|
32504
|
+
Box20,
|
|
32334
32505
|
{
|
|
32335
32506
|
"aria-hidden": "true",
|
|
32336
32507
|
sx: { backgroundColor: "divider", height: height === void 0 ? `calc(100% - ${String(top)}px)` : `${String(height)}px`, left: `${String(left)}px`, pointerEvents: "none", position: "absolute", top: `${String(top)}px`, width: `${String(width)}px` }
|
|
@@ -32358,8 +32529,8 @@ var WaterfallAxis = ({ durationMs, flat, gridColumns: gridColumns2, onFlatChange
|
|
|
32358
32529
|
const trackRef = React124.useRef(null);
|
|
32359
32530
|
const width = useWidth(trackRef);
|
|
32360
32531
|
const { labels, marks } = layoutAxis(durationMs, width);
|
|
32361
|
-
return /* @__PURE__ */
|
|
32362
|
-
|
|
32532
|
+
return /* @__PURE__ */ jsxs137(
|
|
32533
|
+
Box20,
|
|
32363
32534
|
{
|
|
32364
32535
|
"data-testid": WATERFALL_AXIS_TEST_ID,
|
|
32365
32536
|
sx: {
|
|
@@ -32374,7 +32545,7 @@ var WaterfallAxis = ({ durationMs, flat, gridColumns: gridColumns2, onFlatChange
|
|
|
32374
32545
|
zIndex: 1
|
|
32375
32546
|
},
|
|
32376
32547
|
children: [
|
|
32377
|
-
/* @__PURE__ */
|
|
32548
|
+
/* @__PURE__ */ jsx148(Box20, { sx: { alignItems: "center", borderRight: 1, borderRightColor: "divider", display: "flex", gridColumn: "1 / 3", pl: "5px" }, children: onFlatChange && /* @__PURE__ */ jsxs137(
|
|
32378
32549
|
ToggleButtonGroup2,
|
|
32379
32550
|
{
|
|
32380
32551
|
"aria-label": "Operations layout",
|
|
@@ -32386,21 +32557,21 @@ var WaterfallAxis = ({ durationMs, flat, gridColumns: gridColumns2, onFlatChange
|
|
|
32386
32557
|
sx: { "& .MuiToggleButton-root": { fontSize: 11, gap: "3px", height: 18, lineHeight: 1, px: "6px", py: 0, textTransform: "none" } },
|
|
32387
32558
|
value: flat ? "list" : "tree",
|
|
32388
32559
|
children: [
|
|
32389
|
-
/* @__PURE__ */
|
|
32390
|
-
/* @__PURE__ */
|
|
32560
|
+
/* @__PURE__ */ jsxs137(ToggleButton2, { "data-testid": WATERFALL_TREE_VIEW_BUTTON_TEST_ID, value: "tree", children: [
|
|
32561
|
+
/* @__PURE__ */ jsx148(AccountTreeOutlined, { sx: { fontSize: 13 } }),
|
|
32391
32562
|
"Tree"
|
|
32392
32563
|
] }),
|
|
32393
|
-
/* @__PURE__ */
|
|
32394
|
-
/* @__PURE__ */
|
|
32564
|
+
/* @__PURE__ */ jsxs137(ToggleButton2, { "data-testid": WATERFALL_LIST_VIEW_BUTTON_TEST_ID, value: "list", children: [
|
|
32565
|
+
/* @__PURE__ */ jsx148(FormatListBulleted, { sx: { fontSize: 13 } }),
|
|
32395
32566
|
"List"
|
|
32396
32567
|
] })
|
|
32397
32568
|
]
|
|
32398
32569
|
}
|
|
32399
32570
|
) }),
|
|
32400
|
-
/* @__PURE__ */
|
|
32401
|
-
marks.map((x) => /* @__PURE__ */
|
|
32402
|
-
labels.map((label) => /* @__PURE__ */
|
|
32403
|
-
|
|
32571
|
+
/* @__PURE__ */ jsxs137(Box20, { "aria-hidden": "true", ref: trackRef, sx: { mx: TRACK_INSET, position: "relative" }, children: [
|
|
32572
|
+
marks.map((x) => /* @__PURE__ */ jsx148(Box20, { sx: { backgroundColor: "divider", bottom: 0, height: "4px", left: `${String(x)}px`, position: "absolute", width: "1px" } }, x)),
|
|
32573
|
+
labels.map((label) => /* @__PURE__ */ jsx148(
|
|
32574
|
+
Typography15,
|
|
32404
32575
|
{
|
|
32405
32576
|
color: "text.secondary",
|
|
32406
32577
|
component: "span",
|
|
@@ -32465,11 +32636,11 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32465
32636
|
else if (event.key === "ArrowLeft" && !flat && node.children.length > 0) setExpanded(spanId, false);
|
|
32466
32637
|
};
|
|
32467
32638
|
if (spans.length === 0) {
|
|
32468
|
-
return /* @__PURE__ */
|
|
32639
|
+
return /* @__PURE__ */ jsx148(Typography15, { color: "text.secondary", sx: { p: 2 }, variant: "body2", children: "No operations in this trace." });
|
|
32469
32640
|
}
|
|
32470
32641
|
const percentAt = (nano) => bounds.durationMs > 0 ? Number(BigInt(nano) - bounds.startNano) / 1e6 / bounds.durationMs * 100 : 0;
|
|
32471
|
-
return /* @__PURE__ */
|
|
32472
|
-
/* @__PURE__ */
|
|
32642
|
+
return /* @__PURE__ */ jsxs137(Box20, { "aria-label": "Operations waterfall", "data-testid": WATERFALL_TEST_ID, ref: containerRef, role: "tree", sx: { fontSize: 13, minWidth: 0 }, children: [
|
|
32643
|
+
/* @__PURE__ */ jsx148(WaterfallAxis, { durationMs: bounds.durationMs, flat, gridColumns: gridColumns(statusIconsFirst), onFlatChange: waterfallLayout === "toggle" ? setToggledFlat : void 0 }),
|
|
32473
32644
|
rows.map(({ branches, depth, last, node, parent }) => {
|
|
32474
32645
|
const { span } = node;
|
|
32475
32646
|
const issues = getSpanIssues(span);
|
|
@@ -32487,8 +32658,8 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32487
32658
|
const label = formatDuration(durationMs);
|
|
32488
32659
|
const resource = shortResourceName(span.resource_name, span.arn);
|
|
32489
32660
|
const serviceColor = getServiceColor(span.service_name);
|
|
32490
|
-
return /* @__PURE__ */
|
|
32491
|
-
|
|
32661
|
+
return /* @__PURE__ */ jsxs137(
|
|
32662
|
+
Box20,
|
|
32492
32663
|
{
|
|
32493
32664
|
"aria-expanded": hasChildren ? !isCollapsed : void 0,
|
|
32494
32665
|
"aria-level": depth + 1,
|
|
@@ -32507,14 +32678,14 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32507
32678
|
// Tints over the paper, all in one opaque background: the duration label repeats it
|
|
32508
32679
|
// to cover the lead line behind it, which a translucent tint would let through. The
|
|
32509
32680
|
// hover is translucent too (the theme's is an opaque grey), so issue tints show through.
|
|
32510
|
-
"&:hover": { "--row-tint": selected ?
|
|
32681
|
+
"&:hover": { "--row-tint": selected ? alpha6(theme.palette.primary.main, 0.16) : alpha6(theme.palette.text.primary, 0.04) },
|
|
32511
32682
|
// Only the content fades for a row the filters don't match: its background (selection, hover,
|
|
32512
32683
|
// issue tint) keeps its contrast.
|
|
32513
32684
|
"& > *": { opacity: spanMatches && !spanMatches(span.span_id) ? 0.4 : 1 },
|
|
32514
32685
|
"--row-bg": `linear-gradient(var(--row-tint), var(--row-tint)), linear-gradient(var(--row-issue), var(--row-issue)), ${theme.palette.background.paper}`,
|
|
32515
32686
|
// Under the hover and selection tints: an error wins over a warning.
|
|
32516
|
-
"--row-issue": issueBackgrounds && issues.error ?
|
|
32517
|
-
"--row-tint": selected ?
|
|
32687
|
+
"--row-issue": issueBackgrounds && issues.error ? alpha6(theme.palette.error.main, 0.08) : issueBackgrounds && issues.warning ? alpha6(theme.palette.warning.main, 0.1) : "transparent",
|
|
32688
|
+
"--row-tint": selected ? alpha6(theme.palette.primary.main, 0.12) : "transparent",
|
|
32518
32689
|
"background": "var(--row-bg)",
|
|
32519
32690
|
"cursor": "pointer",
|
|
32520
32691
|
"display": "grid",
|
|
@@ -32526,10 +32697,10 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32526
32697
|
"scrollMarginTop": AXIS_HEIGHT
|
|
32527
32698
|
}),
|
|
32528
32699
|
children: [
|
|
32529
|
-
/* @__PURE__ */
|
|
32530
|
-
statusIconsFirst && /* @__PURE__ */
|
|
32531
|
-
/* @__PURE__ */
|
|
32532
|
-
|
|
32700
|
+
/* @__PURE__ */ jsxs137(Box20, { sx: { alignItems: "center", display: "flex", minWidth: 0, pr: 1 }, children: [
|
|
32701
|
+
statusIconsFirst && /* @__PURE__ */ jsx148(Box20, { sx: { display: "inline-flex", flex: "none", gap: "2px", pl: 1, width: STATUS_ICONS_WIDTH }, children: /* @__PURE__ */ jsx148(StatusIcons, { error: issues.error, warning: issues.warning }) }),
|
|
32702
|
+
/* @__PURE__ */ jsxs137(
|
|
32703
|
+
Typography15,
|
|
32533
32704
|
{
|
|
32534
32705
|
color: "text.secondary",
|
|
32535
32706
|
component: "span",
|
|
@@ -32538,21 +32709,21 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32538
32709
|
sx: { display: "flex", flex: 1, fontSize: 11, fontVariantNumeric: "tabular-nums", lineHeight: `${String(ROW_HEIGHT)}px` },
|
|
32539
32710
|
title: "Since the first operation of the trace",
|
|
32540
32711
|
children: [
|
|
32541
|
-
/* @__PURE__ */
|
|
32542
|
-
/* @__PURE__ */
|
|
32712
|
+
/* @__PURE__ */ jsx148(Box20, { component: "span", sx: { flex: 1, textAlign: "right" }, children: offsetMs > 0 ? `+${offset.value}` : offset.value }),
|
|
32713
|
+
/* @__PURE__ */ jsx148(Box20, { component: "span", sx: { flex: "none", pl: "3px", width: OFFSET_UNIT_WIDTH }, children: offset.unit })
|
|
32543
32714
|
]
|
|
32544
32715
|
}
|
|
32545
32716
|
)
|
|
32546
32717
|
] }),
|
|
32547
|
-
/* @__PURE__ */
|
|
32548
|
-
branches.map((runs, level) => runs && /* @__PURE__ */
|
|
32549
|
-
depth > 0 && /* @__PURE__ */
|
|
32550
|
-
/* @__PURE__ */
|
|
32551
|
-
/* @__PURE__ */
|
|
32718
|
+
/* @__PURE__ */ jsxs137(Box20, { sx: { alignItems: "center", borderRight: 1, borderRightColor: "divider", display: "flex", gap: "5px", minWidth: 0, overflow: "hidden", pl: `${String(8 + depth * INDENT)}px`, position: "relative", pr: 1 }, children: [
|
|
32719
|
+
branches.map((runs, level) => runs && /* @__PURE__ */ jsx148(Line, { left: lineX(level) }, level)),
|
|
32720
|
+
depth > 0 && /* @__PURE__ */ jsxs137(Fragment13, { children: [
|
|
32721
|
+
/* @__PURE__ */ jsx148(Line, { height: last ? 12 : void 0, left: lineX(depth - 1) }),
|
|
32722
|
+
/* @__PURE__ */ jsx148(Line, { height: 1, left: lineX(depth - 1), top: 12, width: hasChildren ? 8 : 20 })
|
|
32552
32723
|
] }),
|
|
32553
|
-
hasChildren && !isCollapsed && /* @__PURE__ */
|
|
32554
|
-
hasChildren ? /* @__PURE__ */
|
|
32555
|
-
|
|
32724
|
+
hasChildren && !isCollapsed && /* @__PURE__ */ jsx148(Line, { left: lineX(depth), top: 19 }),
|
|
32725
|
+
hasChildren ? /* @__PURE__ */ jsx148(
|
|
32726
|
+
ButtonBase2,
|
|
32556
32727
|
{
|
|
32557
32728
|
"aria-label": isCollapsed ? "Expand" : "Collapse",
|
|
32558
32729
|
"data-testid": WATERFALL_ROW_TOGGLE_TEST_ID,
|
|
@@ -32563,7 +32734,7 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32563
32734
|
sx: (theme) => ({
|
|
32564
32735
|
// A tint of the text colour: the theme's hover and selected shades match the
|
|
32565
32736
|
// row's own hover, so they wouldn't show on a hovered row.
|
|
32566
|
-
"&:hover": { backgroundColor:
|
|
32737
|
+
"&:hover": { backgroundColor: alpha6(theme.palette.text.primary, 0.12), color: "text.primary" },
|
|
32567
32738
|
"borderRadius": "3px",
|
|
32568
32739
|
"color": "text.secondary",
|
|
32569
32740
|
"flex": "none",
|
|
@@ -32571,21 +32742,21 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32571
32742
|
"width": 14
|
|
32572
32743
|
}),
|
|
32573
32744
|
tabIndex: -1,
|
|
32574
|
-
children: isCollapsed ? /* @__PURE__ */
|
|
32745
|
+
children: isCollapsed ? /* @__PURE__ */ jsx148(KeyboardArrowRight2, { sx: { fontSize: 16 } }) : /* @__PURE__ */ jsx148(KeyboardArrowDown2, { sx: { fontSize: 16 } })
|
|
32575
32746
|
}
|
|
32576
|
-
) : !flat && /* @__PURE__ */
|
|
32577
|
-
/* @__PURE__ */
|
|
32578
|
-
/* @__PURE__ */
|
|
32579
|
-
resource !== "" && resource !== "*" && /* @__PURE__ */
|
|
32580
|
-
!statusIconsFirst && (issues.error || issues.warning) && /* @__PURE__ */
|
|
32747
|
+
) : !flat && /* @__PURE__ */ jsx148(Box20, { sx: { flex: "none", width: 14 } }),
|
|
32748
|
+
/* @__PURE__ */ jsx148(Box20, { sx: { display: "flex", flex: "none" }, children: /* @__PURE__ */ jsx148(AwsServiceIcon, { hideTooltip: true, service: span.service_name, size: "small" }) }),
|
|
32749
|
+
/* @__PURE__ */ jsx148(Typography15, { component: "span", noWrap: true, sx: { flex: "0 1 auto", fontSize: "inherit", fontWeight: 600, minWidth: 0 }, title: span.operation_name, children: span.operation_name }),
|
|
32750
|
+
resource !== "" && resource !== "*" && /* @__PURE__ */ jsx148(Typography15, { color: "text.secondary", component: "span", noWrap: true, sx: { flex: "1 1 0", fontSize: 11, minWidth: 0 }, title: resource, children: resource }),
|
|
32751
|
+
!statusIconsFirst && (issues.error || issues.warning) && /* @__PURE__ */ jsx148(Box20, { sx: { display: "inline-flex", flex: "none", ml: "auto" }, children: /* @__PURE__ */ jsx148(StatusIcons, { error: issues.error, warning: issues.warning }) })
|
|
32581
32752
|
] }),
|
|
32582
|
-
/* @__PURE__ */
|
|
32583
|
-
parentStartPercent !== void 0 && startPercent > parentStartPercent && /* @__PURE__ */
|
|
32584
|
-
/* @__PURE__ */
|
|
32585
|
-
|
|
32753
|
+
/* @__PURE__ */ jsxs137(Box20, { sx: { mx: TRACK_INSET, position: "relative" }, children: [
|
|
32754
|
+
parentStartPercent !== void 0 && startPercent > parentStartPercent && /* @__PURE__ */ jsx148(Box20, { sx: { backgroundColor: serviceColor, height: "1px", left: `${String(parentStartPercent)}%`, opacity: 0.35, position: "absolute", top: 11.5, width: `${String(startPercent - parentStartPercent)}%` } }),
|
|
32755
|
+
/* @__PURE__ */ jsx148(
|
|
32756
|
+
Box20,
|
|
32586
32757
|
{
|
|
32587
32758
|
sx: (theme) => ({
|
|
32588
|
-
background: issues.error ? `repeating-linear-gradient(135deg, ${theme.palette.error.main} 0 4px, ${
|
|
32759
|
+
background: issues.error ? `repeating-linear-gradient(135deg, ${theme.palette.error.main} 0 4px, ${alpha6(theme.palette.error.main, 0.7)} 4px 8px)` : serviceColor,
|
|
32589
32760
|
borderRadius: "1px",
|
|
32590
32761
|
height: 10,
|
|
32591
32762
|
left: `${String(startPercent)}%`,
|
|
@@ -32596,8 +32767,8 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32596
32767
|
})
|
|
32597
32768
|
}
|
|
32598
32769
|
),
|
|
32599
|
-
/* @__PURE__ */
|
|
32600
|
-
|
|
32770
|
+
/* @__PURE__ */ jsx148(
|
|
32771
|
+
Typography15,
|
|
32601
32772
|
{
|
|
32602
32773
|
color: placement === "inside" ? "#fff" : "text.secondary",
|
|
32603
32774
|
component: "span",
|
|
@@ -32626,7 +32797,7 @@ var Waterfall = ({ onSelectSpan, selectedSpanId, spanMatches, spans }) => {
|
|
|
32626
32797
|
};
|
|
32627
32798
|
|
|
32628
32799
|
// src/components/trace-panel/trace-sidebar.tsx
|
|
32629
|
-
import { jsx as
|
|
32800
|
+
import { jsx as jsx149, jsxs as jsxs138 } from "react/jsx-runtime";
|
|
32630
32801
|
var DEFAULT_WIDTH = 560;
|
|
32631
32802
|
var MIN_WIDTH = 360;
|
|
32632
32803
|
var MAX_WIDTH_SHARE = 0.8;
|
|
@@ -32695,8 +32866,8 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32695
32866
|
};
|
|
32696
32867
|
}, [spans, selectedSpanId]);
|
|
32697
32868
|
const rootResource = root2 ? shortResourceName(root2.resource_name, root2.arn) : "";
|
|
32698
|
-
return /* @__PURE__ */
|
|
32699
|
-
|
|
32869
|
+
return /* @__PURE__ */ jsxs138(
|
|
32870
|
+
Box21,
|
|
32700
32871
|
{
|
|
32701
32872
|
"data-testid": TRACE_SIDEBAR_TEST_ID,
|
|
32702
32873
|
ref: sidebarRef,
|
|
@@ -32718,8 +32889,8 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32718
32889
|
width: storedWidth
|
|
32719
32890
|
},
|
|
32720
32891
|
children: [
|
|
32721
|
-
/* @__PURE__ */
|
|
32722
|
-
|
|
32892
|
+
/* @__PURE__ */ jsx149(
|
|
32893
|
+
Box21,
|
|
32723
32894
|
{
|
|
32724
32895
|
"aria-label": "Resize the sidebar",
|
|
32725
32896
|
"aria-orientation": "vertical",
|
|
@@ -32746,22 +32917,22 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32746
32917
|
tabIndex: 0
|
|
32747
32918
|
}
|
|
32748
32919
|
),
|
|
32749
|
-
/* @__PURE__ */
|
|
32750
|
-
/* @__PURE__ */
|
|
32751
|
-
/* @__PURE__ */
|
|
32752
|
-
root2 && /* @__PURE__ */
|
|
32753
|
-
/* @__PURE__ */
|
|
32754
|
-
/* @__PURE__ */
|
|
32755
|
-
rootResource !== "" && rootResource !== "*" && /* @__PURE__ */
|
|
32920
|
+
/* @__PURE__ */ jsxs138(Box21, { sx: { alignItems: "center", borderBottom: 1, borderColor: "divider", display: "flex", gap: 1.5, px: 2, py: 1 }, children: [
|
|
32921
|
+
/* @__PURE__ */ jsxs138(Box21, { sx: { flex: 1, minWidth: 0 }, children: [
|
|
32922
|
+
/* @__PURE__ */ jsx149(Typography16, { color: "text.secondary", component: "div", sx: { lineHeight: 1.5 }, variant: "overline", children: requestTerms === "on" ? "Request" : "Trace root" }),
|
|
32923
|
+
root2 && /* @__PURE__ */ jsxs138(Box21, { "data-testid": TRACE_SIDEBAR_ROOT_HEADING_TEST_ID, sx: { alignItems: "center", display: "flex", gap: 1, minWidth: 0 }, children: [
|
|
32924
|
+
/* @__PURE__ */ jsx149(AwsServiceIcon, { hideTooltip: true, service: root2.service_name, size: "small" }),
|
|
32925
|
+
/* @__PURE__ */ jsx149(Typography16, { noWrap: true, sx: { flex: "0 1 auto", fontWeight: 600, minWidth: 0 }, title: root2.operation_name, variant: "subtitle1", children: root2.operation_name }),
|
|
32926
|
+
rootResource !== "" && rootResource !== "*" && /* @__PURE__ */ jsx149(Typography16, { color: "text.secondary", noWrap: true, sx: { flex: "1 1 0", minWidth: 0 }, title: rootResource, variant: "body2", children: rootResource })
|
|
32756
32927
|
] }),
|
|
32757
|
-
/* @__PURE__ */
|
|
32928
|
+
/* @__PURE__ */ jsx149(Typography16, { color: "text.secondary", variant: "caption", children: [
|
|
32758
32929
|
formatDuration(stats.durationMs),
|
|
32759
32930
|
pluralize(spans.length, "op"),
|
|
32760
32931
|
...stats.errors > 0 ? [pluralize(stats.errors, "error")] : [],
|
|
32761
32932
|
...stats.warnings > 0 ? [pluralize(stats.warnings, "warning")] : []
|
|
32762
32933
|
].join(" \xB7 ") })
|
|
32763
32934
|
] }),
|
|
32764
|
-
/* @__PURE__ */
|
|
32935
|
+
/* @__PURE__ */ jsxs138(
|
|
32765
32936
|
ToggleButtonGroup3,
|
|
32766
32937
|
{
|
|
32767
32938
|
"aria-label": "Trace view",
|
|
@@ -32772,14 +32943,14 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32772
32943
|
size: "small",
|
|
32773
32944
|
value: view,
|
|
32774
32945
|
children: [
|
|
32775
|
-
/* @__PURE__ */
|
|
32776
|
-
/* @__PURE__ */
|
|
32946
|
+
/* @__PURE__ */ jsx149(ToggleButton3, { "data-testid": TRACE_SIDEBAR_WATERFALL_BUTTON_TEST_ID, sx: { px: 1.5, py: 0.25, textTransform: "none" }, value: "waterfall", children: "Operations" }),
|
|
32947
|
+
/* @__PURE__ */ jsx149(ToggleButton3, { "data-testid": TRACE_SIDEBAR_MAP_BUTTON_TEST_ID, sx: { px: 1.5, py: 0.25, textTransform: "none" }, value: "map", children: "Flow" })
|
|
32777
32948
|
]
|
|
32778
32949
|
}
|
|
32779
32950
|
),
|
|
32780
|
-
/* @__PURE__ */
|
|
32951
|
+
/* @__PURE__ */ jsx149(IconButton8, { "aria-label": "Close", "data-testid": EVENT_DETAILS_CLOSE_BUTTON_TEST_ID, onClick: onClose, size: "small", children: /* @__PURE__ */ jsx149(Close4, {}) })
|
|
32781
32952
|
] }),
|
|
32782
|
-
/* @__PURE__ */
|
|
32953
|
+
/* @__PURE__ */ jsx149(Box21, { ref: traceViewRef, sx: { borderBottom: 1, borderColor: "divider", display: "flex", flex: `0 0 ${String(storedSplit * 100)}%`, flexDirection: "column", minHeight: 0, overflow: "auto", position: "relative" }, children: view === "waterfall" ? /* @__PURE__ */ jsx149(Waterfall, { onSelectSpan, selectedSpanId, spanMatches, spans }) : /* @__PURE__ */ jsx149(Box21, { sx: { height: "100%" }, children: /* @__PURE__ */ jsx149(ReactFlowProvider, { children: /* @__PURE__ */ jsx149(
|
|
32783
32954
|
TraceGraph,
|
|
32784
32955
|
{
|
|
32785
32956
|
hideMiniMap: true,
|
|
@@ -32789,8 +32960,8 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32789
32960
|
spans: { data: spans, error: void 0, loading: false }
|
|
32790
32961
|
}
|
|
32791
32962
|
) }) }) }),
|
|
32792
|
-
/* @__PURE__ */
|
|
32793
|
-
|
|
32963
|
+
/* @__PURE__ */ jsx149(Box21, { sx: { flexShrink: 0, position: "relative" }, children: /* @__PURE__ */ jsx149(
|
|
32964
|
+
Box21,
|
|
32794
32965
|
{
|
|
32795
32966
|
"aria-label": "Resize the operation details",
|
|
32796
32967
|
"aria-orientation": "horizontal",
|
|
@@ -32818,7 +32989,7 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32818
32989
|
tabIndex: 0
|
|
32819
32990
|
}
|
|
32820
32991
|
) }),
|
|
32821
|
-
/* @__PURE__ */
|
|
32992
|
+
/* @__PURE__ */ jsx149(Box21, { sx: { flex: 1, minHeight: 0 }, children: selectedSpan ? /* @__PURE__ */ jsx149(EventDetails, { selectedEvent: selectedSpan }) : /* @__PURE__ */ jsx149(Typography16, { color: "text.secondary", sx: { p: 3, textAlign: "center" }, variant: "body2", children: "The selected operation is not part of this trace." }) })
|
|
32822
32993
|
]
|
|
32823
32994
|
}
|
|
32824
32995
|
);
|
|
@@ -32826,10 +32997,10 @@ var TraceSidebar = ({ onClose, onSelectSpan, selectedSpanId, spanMatches, spans
|
|
|
32826
32997
|
|
|
32827
32998
|
// src/components/worker-error-message/worker-error-message.tsx
|
|
32828
32999
|
import { ErrorOutline as ErrorOutline2 } from "@mui/icons-material";
|
|
32829
|
-
import { Alert as Alert6, AlertTitle as AlertTitle2, Box as
|
|
32830
|
-
import { jsx as
|
|
32831
|
-
var WorkerErrorMessage = ({ error, onRetry }) => /* @__PURE__ */
|
|
32832
|
-
|
|
33000
|
+
import { Alert as Alert6, AlertTitle as AlertTitle2, Box as Box22, Button as Button7, Typography as Typography17 } from "@mui/material";
|
|
33001
|
+
import { jsx as jsx150, jsxs as jsxs139 } from "react/jsx-runtime";
|
|
33002
|
+
var WorkerErrorMessage = ({ error, onRetry }) => /* @__PURE__ */ jsx150(
|
|
33003
|
+
Box22,
|
|
32833
33004
|
{
|
|
32834
33005
|
sx: {
|
|
32835
33006
|
alignItems: "center",
|
|
@@ -32839,17 +33010,17 @@ var WorkerErrorMessage = ({ error, onRetry }) => /* @__PURE__ */ jsx149(
|
|
|
32839
33010
|
justifyContent: "center",
|
|
32840
33011
|
p: 4
|
|
32841
33012
|
},
|
|
32842
|
-
children: /* @__PURE__ */
|
|
33013
|
+
children: /* @__PURE__ */ jsxs139(
|
|
32843
33014
|
Alert6,
|
|
32844
33015
|
{
|
|
32845
|
-
icon: /* @__PURE__ */
|
|
33016
|
+
icon: /* @__PURE__ */ jsx150(ErrorOutline2, { fontSize: "large" }),
|
|
32846
33017
|
severity: "error",
|
|
32847
33018
|
sx: { maxWidth: 600, width: "100%" },
|
|
32848
33019
|
children: [
|
|
32849
|
-
/* @__PURE__ */
|
|
32850
|
-
/* @__PURE__ */
|
|
32851
|
-
/* @__PURE__ */
|
|
32852
|
-
onRetry && /* @__PURE__ */
|
|
33020
|
+
/* @__PURE__ */ jsx150(AlertTitle2, { sx: { fontWeight: "bold" }, children: "Unable to Start Span Filtering" }),
|
|
33021
|
+
/* @__PURE__ */ jsx150(Typography17, { sx: { mb: 2 }, variant: "body2", children: "App Inspector couldn't start the background worker that filters and sorts operations. This is usually caused by a Content-Security-Policy blocking Web Workers in this environment." }),
|
|
33022
|
+
/* @__PURE__ */ jsx150(Typography17, { sx: { fontFamily: "monospace", mb: 2 }, variant: "caption", children: error.message }),
|
|
33023
|
+
onRetry && /* @__PURE__ */ jsx150(Box22, { sx: { display: "flex", justifyContent: "flex-start" }, children: /* @__PURE__ */ jsx150(
|
|
32853
33024
|
Button7,
|
|
32854
33025
|
{
|
|
32855
33026
|
"aria-label": "Retry starting the spans filter worker",
|
|
@@ -33567,7 +33738,7 @@ var useSpans = () => {
|
|
|
33567
33738
|
};
|
|
33568
33739
|
|
|
33569
33740
|
// src/pages/spans-list-page.tsx
|
|
33570
|
-
import { jsx as
|
|
33741
|
+
import { jsx as jsx151, jsxs as jsxs140 } from "react/jsx-runtime";
|
|
33571
33742
|
var SpansListPage = () => {
|
|
33572
33743
|
const api = useAppInspectorApi();
|
|
33573
33744
|
const {
|
|
@@ -33653,10 +33824,10 @@ var SpansListPage = () => {
|
|
|
33653
33824
|
switch (phase) {
|
|
33654
33825
|
case "CHECKING_STATUS":
|
|
33655
33826
|
case "CONNECTING_WS": {
|
|
33656
|
-
return /* @__PURE__ */
|
|
33827
|
+
return /* @__PURE__ */ jsx151(StatusMessage, { phase });
|
|
33657
33828
|
}
|
|
33658
33829
|
case "DISABLED": {
|
|
33659
|
-
return /* @__PURE__ */
|
|
33830
|
+
return /* @__PURE__ */ jsx151(
|
|
33660
33831
|
StatusMessage,
|
|
33661
33832
|
{
|
|
33662
33833
|
onEnable: handleEnable,
|
|
@@ -33665,7 +33836,7 @@ var SpansListPage = () => {
|
|
|
33665
33836
|
);
|
|
33666
33837
|
}
|
|
33667
33838
|
case "INCOMPATIBLE": {
|
|
33668
|
-
return /* @__PURE__ */
|
|
33839
|
+
return /* @__PURE__ */ jsx151(
|
|
33669
33840
|
StatusMessage,
|
|
33670
33841
|
{
|
|
33671
33842
|
localstackVersion,
|
|
@@ -33676,12 +33847,12 @@ var SpansListPage = () => {
|
|
|
33676
33847
|
}
|
|
33677
33848
|
case "LIVE": {
|
|
33678
33849
|
if (workerError) {
|
|
33679
|
-
return /* @__PURE__ */
|
|
33850
|
+
return /* @__PURE__ */ jsx151(WorkerErrorMessage, { error: workerError, onRetry: retryWorker });
|
|
33680
33851
|
}
|
|
33681
33852
|
break;
|
|
33682
33853
|
}
|
|
33683
33854
|
case "UNREACHABLE": {
|
|
33684
|
-
return /* @__PURE__ */
|
|
33855
|
+
return /* @__PURE__ */ jsx151(
|
|
33685
33856
|
StatusMessage,
|
|
33686
33857
|
{
|
|
33687
33858
|
onRetry: handleRetry,
|
|
@@ -33690,9 +33861,9 @@ var SpansListPage = () => {
|
|
|
33690
33861
|
);
|
|
33691
33862
|
}
|
|
33692
33863
|
}
|
|
33693
|
-
return /* @__PURE__ */
|
|
33694
|
-
/* @__PURE__ */
|
|
33695
|
-
|
|
33864
|
+
return /* @__PURE__ */ jsxs140(Paper2, { square: true, sx: { ...NATIVE_SCROLLBARS, display: "flex", flexDirection: "row", flexGrow: 1, minHeight: 0, overflow: "hidden" }, children: [
|
|
33865
|
+
/* @__PURE__ */ jsxs140(
|
|
33866
|
+
Box23,
|
|
33696
33867
|
{
|
|
33697
33868
|
"data-testid": SPANS_LIST_PAGE_TEST_ID,
|
|
33698
33869
|
sx: {
|
|
@@ -33703,7 +33874,7 @@ var SpansListPage = () => {
|
|
|
33703
33874
|
minWidth: 0
|
|
33704
33875
|
},
|
|
33705
33876
|
children: [
|
|
33706
|
-
/* @__PURE__ */
|
|
33877
|
+
/* @__PURE__ */ jsx151(
|
|
33707
33878
|
EmulatorVersionBanner,
|
|
33708
33879
|
{
|
|
33709
33880
|
compatibility: bannerDismissed && versionCompatibility === "warning" ? "ok" : versionCompatibility,
|
|
@@ -33713,7 +33884,7 @@ var SpansListPage = () => {
|
|
|
33713
33884
|
} : void 0
|
|
33714
33885
|
}
|
|
33715
33886
|
),
|
|
33716
|
-
/* @__PURE__ */
|
|
33887
|
+
/* @__PURE__ */ jsx151(
|
|
33717
33888
|
SpansList,
|
|
33718
33889
|
{
|
|
33719
33890
|
clearingSpans,
|
|
@@ -33740,7 +33911,7 @@ var SpansListPage = () => {
|
|
|
33740
33911
|
]
|
|
33741
33912
|
}
|
|
33742
33913
|
),
|
|
33743
|
-
selectedSpanId !== void 0 && rootSpanId !== void 0 && /* @__PURE__ */
|
|
33914
|
+
selectedSpanId !== void 0 && rootSpanId !== void 0 && /* @__PURE__ */ jsx151(
|
|
33744
33915
|
TraceSidebar,
|
|
33745
33916
|
{
|
|
33746
33917
|
onClose: closeSidebar,
|