Skip to content

Commit

Permalink
[APM] checks if is serverless first in order to show java lambda metr…
Browse files Browse the repository at this point in the history
…ics (#142849)

* [APM] checks if is serverless first in order to show java lambda metrics

* addressing pr comments
  • Loading branch information
cauemarcondes authored Oct 6, 2022
1 parent ca04402 commit 9ceaab7
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,16 @@ export async function getMetricsChartDataByAgent({
start,
end,
};
if (isJavaAgentName(agentName)) {
const serverlessAgent = isServerlessAgent(serviceRuntimeName);

if (isJavaAgentName(agentName) && !serverlessAgent) {
return getJavaMetricsCharts({
...options,
serviceNodeName,
});
}

if (isServerlessAgent(serviceRuntimeName)) {
if (serverlessAgent) {
return getServerlessAgentMetricCharts(options);
}

Expand Down

0 comments on commit 9ceaab7

Please sign in to comment.