mirror of
https://github.com/apache/skywalking-booster-ui.git
synced 2025-05-06 10:05:05 +00:00
update
This commit is contained in:
parent
176a7fd769
commit
f74074d737
@ -238,25 +238,26 @@ limitations under the License. -->
|
||||
fixSpansSize.value = fixSpans.length;
|
||||
for (const id of Object.keys(segmentGroup)) {
|
||||
const currentSegment = segmentGroup[id].sort((a: Span, b: Span) => b.parentSpanId - a.parentSpanId);
|
||||
for (const s of currentSegment) {
|
||||
const index = currentSegment.findIndex((i: Span) => i.spanId === s.parentSpanId);
|
||||
for (const span of currentSegment) {
|
||||
const index = currentSegment.findIndex((i: Span) => i.spanId === span.parentSpanId);
|
||||
if (index > -1) {
|
||||
if (
|
||||
(currentSegment[index].isBroken && currentSegment[index].parentSpanId === -1) ||
|
||||
!currentSegment[index].isBroken
|
||||
) {
|
||||
currentSegment[index].children.push(s);
|
||||
currentSegment[index].children.push(span);
|
||||
currentSegment[index].children.sort((a: Span, b: Span) => a.spanId - b.spanId);
|
||||
}
|
||||
}
|
||||
if (s.isBroken) {
|
||||
if (span.isBroken) {
|
||||
const children = props.data.filter((span: Span) =>
|
||||
span.refs.find(
|
||||
(d) => d.traceId === s.traceId && d.parentSegmentId === s.segmentId && d.parentSpanId === s.spanId,
|
||||
(d) =>
|
||||
d.traceId === span.traceId && d.parentSegmentId === span.segmentId && d.parentSpanId === span.spanId,
|
||||
),
|
||||
);
|
||||
if (children.length) {
|
||||
s.children.push(...children);
|
||||
span.children.push(...children);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user