-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
[#noissue] fix servermap numaric display #10931
[#noissue] fix servermap numaric display #10931
Conversation
BillionaireDY
commented
Apr 18, 2024
- display
- node instance count
- unit of average response time (ms)
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.
- Change transactionInfoStatus svg string variable name
- Handle when there's no edge
const { transactionInfo } = nodeData; | ||
const transactionStatus = getTransactionStatusSVGCircle(transactionInfo, !transactionInfo); |
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.
const transactionStatus = getTransactionStatusSVGCircle(transactionInfo, !transactionInfo); | |
const transactionStatusSVGString = getTransactionStatusSVGCircle(transactionInfo, !transactionInfo); |
return ( | ||
'data:image/svg+xml;charset=utf-8,' + | ||
encodeURIComponent(` | ||
<svg xmlns="http://www.w3.org/2000/svg" width="100" height="100" xmlns:xlink="http://www.w3.org/1999/xlink"> | ||
${getTransactionStatusSVGCircle(transactionInfo, !transactionInfo)} | ||
${renderNode ? renderNode(nodeData, transactionStatus) : transactionStatus} |
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.
${renderNode ? renderNode(nodeData, transactionStatus) : transactionStatus} | |
${renderNode ? renderNode(nodeData, transactionStatusSVGString) : transactionStatusSVGString} |
renderEdgeLabel={(edge: MergedEdge) => { | ||
if (edge?.transactionInfo?.totalCount) { | ||
return `${addCommas(edge?.transactionInfo?.totalCount)}${edge.transactionInfo?.avgResponseTime ? ` (${edge.transactionInfo.avgResponseTime} ms)` : ''}`; | ||
} else if (edge.edges) { |
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.
} else if (edge.edges) { | |
} else if (edge?.edges) { |
fe41d0a
to
7cac84d
Compare