Troubleshooting
Quick Diagnosis
# Check container status
docker ps | grep smart-buffer
# Check recent logs
docker logs smart-buffer --tail 50 2>&1 | grep -i error
# Test priority classification
curl -X POST http://localhost:8080/events \
-H "Content-Type: application/json" \
-d '{"severity": "critical", "message": "test"}'
Common Issues
Important messages not prioritized
Cause: Classification rules not matching message attributes
# Check classification output
docker logs smart-buffer --tail 20 2>&1 | grep priority
Fix: Replace the severity declaration inside the existing classification mapping
when your field is level:
let severity = this.level.or("info").string().lowercase()
All messages getting same score
Cause: Classification repeatedly falls to the default case
Fix: Check field existence and add explicit logging:
- mapping: |
root = this
root._debug_severity = this.severity.or("MISSING")
root._debug_category = this.category.or("MISSING")
# ... rest of classification
Archive messages never sent (starvation)
Cause: Age boost not high enough or timestamp parsing failing
Fix: Replace the age boost declaration inside the existing classification
mapping, after it calculates age_seconds and before it calculates priority_score:
let age_boost = match {
$age_seconds > 3600 => 950,
$age_seconds > 600 => 500,
_ => 0
}
Messages not sorted in batch
Cause: Sort processor not applied to output batch
Fix: Forward the complete event with its upstream priority score; ordering belongs to the destination queue:
output:
broker:
outputs:
- stdout: {}
Buffer filling up
Cause: Output slower than input
Fix: Increase buffer limit or add overflow handling:
buffer:
memory:
limit: 100000 # Increase capacity
# Or add overflow to file
output:
fallback:
- http_client:
url: http://localhost:8080/events
verb: POST
- file:
path: /tmp/overflow.json
Still stuck?
- Add debug logging:
logger: {level: DEBUG} - Check the Complete Pipeline for reference config
- Review Priority Queues for separate queue routing