-
Notifications
You must be signed in to change notification settings - Fork 11
feat: highlight error span on partial or full error #773
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 11 commits
b1ce950
a407cf3
254a519
0593e3f
4f83aaa
bc46627
db30235
9ba8708
fd9df26
150943f
6b75bdb
c3f9b0a
093f57f
c6898e5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,4 +3,5 @@ export interface SpanNameCellData { | |
| protocolName: string; | ||
| name: string; | ||
| color?: string; | ||
| error?: boolean; | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -41,7 +41,8 @@ export class WaterfallChartService { | |
| $$spanName: { | ||
| name: datum.name, | ||
| serviceName: datum.serviceName, | ||
| protocolName: datum.protocolName | ||
| protocolName: datum.protocolName, | ||
| error: datum.errorCount > 0 | ||
| }, | ||
| $$iconType: this.iconLookupService.forSpanType(datum.spanType)!, | ||
| getChildren: () => of([]), | ||
|
|
@@ -82,7 +83,6 @@ export class WaterfallChartService { | |
| // Do DFS | ||
| while (sequenceNodes.length !== 0) { | ||
| const node = sequenceNodes.shift()!; | ||
|
|
||
| if (node.$$state.expanded) { | ||
| segments.push({ | ||
| id: node.id, | ||
|
|
@@ -123,7 +123,10 @@ export class WaterfallChartService { | |
| const node = nodes.shift()!; | ||
| let color; | ||
|
|
||
| if (colorMap.has(node.serviceName)) { | ||
| if (node.$$spanName.error) { | ||
|
||
| // If span contains an error | ||
| color = Color.Red5; | ||
| } else if (colorMap.has(node.serviceName)) { | ||
| // ServiceName seen before. Use existing service color | ||
| color = colorMap.get(node.serviceName)!; | ||
| } else { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit:
hasErrorwould convey it is boolean and not an error stringThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah,
I have made the changes