Skip to content

Add push notification trace UUID tracking for debugging#397

Open
jirkah wants to merge 1 commit intomasterfrom
claude/trace-push-notifications-r56tN
Open

Add push notification trace UUID tracking for debugging#397
jirkah wants to merge 1 commit intomasterfrom
claude/trace-push-notifications-r56tN

Conversation

@jirkah
Copy link
Copy Markdown

@jirkah jirkah commented Mar 20, 2026

Summary

This change adds support for tracking push notifications through a trace UUID, enabling better debugging and tracing of push notification flows across the system.

Key Changes

  • Added push_trace_uuid parameter to the push notification workflow:

    • Added as optional parameter to send_push_notification() method with default empty string
    • Extracted from incoming bus events via WAZO_PUSH_TRACE_UUID field
    • Included in push notification payloads sent to the bus
  • Enhanced logging throughout the push notification lifecycle:

    • Log push trace UUID when sending push notifications in services.py
    • Log push trace UUID when cancelling push notifications in services.py
    • Log push trace UUID when publishing events in notifier.py (both send and cancel operations)
    • Log push trace UUID in bus consumer when receiving push notification requests
  • Updated test coverage:

    • Added WAZO_PUSH_TRACE_UUID to test event data
    • Updated test assertions to verify trace UUID is passed through the call chain

Implementation Details

  • The trace UUID is optional and defaults to an empty string for backward compatibility
  • Logging includes the trace UUID alongside user UUID and call ID for correlation
  • The trace UUID flows through the entire push notification pipeline: bus consumer → service → notifier → bus producer

https://claude.ai/code/session_0193K1vomcUqeAw3TAif3MCK


Note

Low Risk
Low risk: changes are additive (optional push_trace_uuid field) and primarily affect logging and bus payload metadata for push notifications/cancellation.

Overview
Adds end-to-end propagation of an optional push_trace_uuid for mobile push notifications, extracted from UserEvent (WAZO_PUSH_TRACE_UUID) and included in the payload sent on the bus.

Improves observability by logging the trace UUID when receiving, sending, publishing, and cancelling push notifications, and updates the test_bus_consume assertion to verify the new argument is passed through.

Written by Cursor Bugbot for commit 56489ee. This will update automatically on new commits. Configure here.

Extract push_trace_uuid from the Pushmobile UserEvent, include it in the
notification payload, and log it at each step (bus_consume, service, notifier)
for end-to-end push notification tracing.

https://claude.ai/code/session_0193K1vomcUqeAw3TAif3MCK
@sonarqubecloud
Copy link
Copy Markdown

@wazo-community-zuul
Copy link
Copy Markdown
Contributor

Build succeeded.
https://zuul.wazo.community/zuul/t/local/buildset/a70b699287fb4e228baa3435f328c2bf

✔️ tox-linters SUCCESS in 3m 03s
✔️ wazo-tox-py311 SUCCESS in 3m 04s
✔️ debian-packaging-bookworm SUCCESS in 2m 55s
✔️ calld-tox-integration SUCCESS in 1h 07m 27s

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.

2 participants