# Test Message

> Send a known message through the live pipeline to verify end-to-end health.

- **Category**: Integration
- **Subcategory**: System Management
- **Canonical URL**: https://designpattern.fyi/patterns/test_message/

---

## Description
Clean, reusable architecture pattern.


## Use Cases
Payment pipeline health check — every 60 seconds, a synthetic PaymentTestMessage is injected. It flows through all 6 processing steps. A test monitor at the end confirms receipt within 5 seconds. If the test message does not arrive — PagerDuty fires. Real payment failures are detected before customers notice.





## Trade-offs


### Advantages

- End-to-end pipeline health validation — not just component health

- Detects configuration issues, routing bugs, and processing failures in production

- Synthetic messages are controllable and observable

- Low overhead — one test message per interval vs real traffic load




### Considerations & Drawbacks

- Test messages must be identifiable and handled separately from real messages

- Risk of test messages polluting production data if not filtered correctly

- False positives if test observer has its own issues

- Requires test observer infrastructure to be maintained







---
**Reference**: [Original Source](https://www.enterpriseintegrationpatterns.com/patterns/messaging/TestMessage.html)

