OTF Mattermost DB Store Errors
resolvedWorkspace
[OTF] Optimified
Created
Sat Mar 14
Updated
Tue Mar 24
Content
## Description
Mattermost on Railway (project: otf-n8n-mattermost-umami) entered an 8-hour error loop on 2026-03-14 from ~07:14 to ~15:25 UTC. Every 1-2 minutes, the following errors repeated:
- `Error occurred getting all pending statuses`
- `Failed to fetch dnd statues from store`
- `Failed to schedule job`
- `Failed to get system bot`
- `Unable to cleanup command webhook store`
- `Unable to cleanup token store`
- `Invalid session` with HTTP hijacked connection errors
The service remained online in Railway but was functionally degraded — background jobs, session management, and status tracking all failed.
## Steps to Reproduce
Three services (n8n, Mattermost, Umami) share a single Postgres instance on Railway. Under load, Postgres connection limits are exhausted, causing cascading failures in Mattermost's store layer.
## Resolution
Service self-recovered around 15:25 UTC on 2026-03-14. No manual intervention required. Logs returned to normal from 2026-03-15 onward.
**Recommendation:** Monitor shared Postgres connection usage. Consider adding `?connection_limit=10` to each service's DATABASE_URL or splitting into separate Postgres instances if this recurs.
## Related
- Tech asset: [[otf-mattermost]]