A method and apparatus in a distributed processing environment for tracing events
includes receiving a request to trace an event on a local processor, acquiring
a sequence identifier associated with the local processor that associates the event
with a chronological sequence of events on the local processor, storing the sequence
identifier and information about the event in a local event trace associated with
the local processor, providing the sequence identifer and information about the
event to a remote processor for storage in a remote event trace. Consolidating
the event traces from multiple processors into a single chronological event trace
includes accessing a local event trace having one or more local trace events associated
with the local processor, identifying a trace event entry having a local sequence
identifier and referencing a remote processor, accessing a remote event trace associated
with the remote processor and having a remote trace event entry matching the local
sequence identifier, comparing the remote trace event entry with the local sequence
identifier and one or more local trace events in the local event trace, and inserting
the remote trace event entry into the local event trace based upon the comparison.