Skip to content

Commit

Permalink
[APM] Lowercase agent names so icons work
Browse files Browse the repository at this point in the history
.NET agent name can be reported as "dotNet" instead of "dotnet". Lowercase the key so either one will work.
  • Loading branch information
smith committed May 15, 2020
1 parent a8e8211 commit 80221d9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,13 @@ storiesOf('app/ServiceMap/Cytoscape', module)
'agent.name': 'dotnet'
}
},
{
data: {
id: 'dotNet',
'service.name': 'dotNet service',
'agent.name': 'dotNet'
}
},
{
data: {
id: 'go',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ const agentIcons: { [key: string]: string } = {
function getAgentIcon(agentName?: string) {
// RUM can have multiple names. Normalize it
const normalizedAgentName = isRumAgentName(agentName) ? 'js-base' : agentName;
return normalizedAgentName && agentIcons[normalizedAgentName];
return normalizedAgentName && agentIcons[normalizedAgentName.toLowerCase()];
}

function getSpanIcon(type?: string, subtype?: string) {
Expand Down

0 comments on commit 80221d9

Please sign in to comment.