2 months ago
I had a service recently have an issue which caused a bunch of internal server errors. I didn't realise this until a customer contacted me about it.
I would like to be able to set up monitoring alerts for response codes similar to how you can set them up for CPU/Memory usage. Not sure if this is possible currently, I would love to have this as a feature if it isn't though.
0 Threads mention this feature
1 Replies
2 months ago
Agree that this would be sweet, would love for Railway to ship something like this eventually.
That said, If you're looking for a solve for this in the mean time you could try the following:
deploy a Grafana Stack template including Grafana (visualization + alerts) and Loki (log database)
process your service's logs using Locomotive- this lets you pipe your Railway logs into Loki.
add monitoring using alerts in Grafana. You'd basically just write a LogQL query to check if there's been a x% increase in 500s / a specific log message even
I know it's a round-about solution but by ingesting, querying, and monitoring on logs you can alert on virtually anything.