Skip to content

Commit

Permalink
Add 2nd null check
Browse files Browse the repository at this point in the history
  • Loading branch information
obenkenobi committed Sep 17, 2024
1 parent 947466c commit bbb433f
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,9 @@ private void recordMessageBrokerMetrics(MessageConsumeParameters messageConsumeP
}

private void recordFaasAttributes(CloudParameters cloudParameters) {
setAgentAttribute(AttributeNames.CLOUD_PLATFORM, cloudParameters.getPlatform());
if (cloudParameters.getPlatform() != null) {
setAgentAttribute(AttributeNames.CLOUD_PLATFORM, cloudParameters.getPlatform());
}
if (cloudParameters.getResourceId() != null) {
setAgentAttribute(AttributeNames.CLOUD_RESOURCE_ID, cloudParameters.getResourceId());
}
Expand Down

0 comments on commit bbb433f

Please sign in to comment.