Skip to content
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

JMS instrumentation: do not create spans if no messages are received #2091

Merged
merged 5 commits into from
Jan 25, 2021

Conversation

malafeev
Copy link
Contributor

fix #1989

…ssages are received

Signed-off-by: Sergei Malafeev <sergei@malafeev.org>
Copy link
Contributor

@breedx-splk breedx-splk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. Thanks for picking this up! 🎉

destination = MessageDestination.UNKNOWN;
}
// Do not create span when no message is received
return;
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a huge deal, but my preference is to remove the redundant else when there is a return above it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Signed-off-by: Sergei Malafeev <sergei@malafeev.org>
@Advice.Enter long startTime,
@Advice.Return Message message,
@Advice.Thrown Throwable throwable) {
MessageDestination destination;
if (message == null) {
destination =
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JmsSessionInstrumentation can be removed now, right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed

Sergei Malafeev added 2 commits January 22, 2021 20:47
Signed-off-by: Sergei Malafeev <sergei@malafeev.org>
@malafeev
Copy link
Contributor Author

looks like ready to merge.
can anybody with permissions merge it?

@iNikem iNikem merged commit 54d0002 into open-telemetry:master Jan 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

JMS instrumentation creates spans when no messages are received
5 participants