HTTP 504 Gateway Timeout during high-cardinality PromQL execution
Query Timeout Behavior in Prometheus Prometheus utilizes a global --query.timeout flag to prevent resource exhaustion from long-running queries. While the HTTP API allows for per-request timeout overrides, the server must manage the lifecycle of the underlying PromQL engine process when these limits are reached or when a client abruptly closes the connection