Home / Companies / Honeycomb / Blog / Post Details
Content Deep Dive

Understanding Distributed Tracing with a Message Bus

Blog post from Honeycomb

Post Details
Company
Date Published
Author
Martin Thwaites
Word Count
1,526
Language
English
Hacker News Points
-
Summary

Debugging systems with the introduction of a message queue can complicate trace propagation, as traditional methods using distributed traces may not fully apply. The post explores the differences between synchronous systems, where user actions map directly to traces, and asynchronous systems with message queues, where mapping becomes more complex due to the indirect correspondence of user actions to events. It discusses the concept of trace propagation and how OpenTelemetry and W3C tracing standards help in linking spans and traces, particularly with message-driven architectures. The article provides examples of different scenarios, such as email sending and account reconciliation, to illustrate the challenges and solutions for tracing in event-driven systems. It highlights the use of span links versus parent-child relationships to maintain context across systems, using Azure Service Bus as a practical example to demonstrate how metadata and activity contexts can be used to propagate trace information. The post emphasizes the importance of designing debugging experiences to accommodate the complexities of asynchronous messaging and suggests using OpenTelemetry propagation APIs for consistency across different applications and languages.