Silent Go bug blocked dead push subscription cleanup, causing endless wasted requests
A developer working on agentrq, a Go backend for an AI agent task manager, discovered a logic bug in the web push notification path that had never triggered any error or alert. The flaw stemmed from a misunderstanding of Go's net/http contract: a 410 Gone response is treated as a successful request, so the error-handling branch meant to delete expired subscriptions was never reached. Because the cleanup code was unreachable from the start, stale push subscription records accumulated in the database without any upper bound. Every subsequent notification event continued attempting delivery to already-dead endpoints, adding a small but permanent overhead per dead subscription per event. The bug caused no crash or visible failure, making it invisible to standard monitoring while silently degrading system efficiency over time.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.
Discussion (0)
Log in to join the discussion and vote.
Log in