Skip to content

[aio-pika] Enable consumer callback tracing#795

Merged
GSVarsha merged 2 commits into
instana:mainfrom
tobmi1:aio_pika_consume_tracing
Sep 5, 2025
Merged

[aio-pika] Enable consumer callback tracing#795
GSVarsha merged 2 commits into
instana:mainfrom
tobmi1:aio_pika_consume_tracing

Conversation

@tobmi1

@tobmi1 tobmi1 commented Sep 2, 2025

Copy link
Copy Markdown
Contributor

Addresses #794.

The following changes were made:

  • Move the execution of the consumer callback in the aio-pika´ consume wrapper into the with` statement that constitutes the consumer span. This enables tracing of further calls made in the consumer callback function.
  • Add a test to check if exceptions thrown in the consumer callback function are recorded by Instana. This fails against the current main branch and passes with the changes in this PR.

Signed-off-by: Tobias Michels <66688058+tobmi1@users.noreply.github.com>
… be included in the trace

Signed-off-by: Tobias Michels <66688058+tobmi1@users.noreply.github.com>
@tobmi1 tobmi1 marked this pull request as ready for review September 2, 2025 19:21
@tobmi1 tobmi1 requested a review from a team as a code owner September 2, 2025 19:21
@GSVarsha GSVarsha self-assigned this Sep 5, 2025
@GSVarsha GSVarsha added this to the H2-2025 milestone Sep 5, 2025

@GSVarsha GSVarsha left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good to me!

@GSVarsha GSVarsha merged commit d412bd7 into instana:main Sep 5, 2025
17 of 19 checks passed
@GSVarsha GSVarsha linked an issue Sep 5, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: aio-pika wrapper does not trace consumer callback

2 participants