gRPC status 8: RESOURCE_EXHAUSTED

RESOURCE_EXHAUSTED is gRPC status code 8. A resource ran out: a quota, a rate limit, memory, or the maximum message size.

Updated

Usual causes

  • The message was larger than the receiver's limit. gRPC libraries default to 4 MiB for received messages.
  • A rate limit or per-user quota was hit.
  • The server ran out of memory or of a bounded resource such as connections or worker slots.

What to check

  1. The status message: a size limit reads like received message larger than max, with both sizes.
  2. The receive limit on whichever side rejected it, such as MaxRecvMsgSize in Go or max_receive_message_length in Python.
  3. Rate limit headers or a QuotaFailure or RetryInfo detail in the trailers.

What it looks like

A typical error, as a Go client prints it: rpc error: code = ResourceExhausted desc = grpc: received message larger than max (5242880 vs. 4194304)

Retry, and the HTTP equivalent

RESOURCE_EXHAUSTED
Code8
NameRESOURCE_EXHAUSTED
In istek's status barresource_exhausted
RetryFor a rate limit, yes, after the delay the server asks for. For a size limit, never; the message stays too big.
HTTP status429

istek names the status of every call it makes, resource_exhausted included, and explains transport failures in plain words. See istek.

istek, $29 once

macOS 14.0+ · Apple Silicon · no account, no telemetry

Buy istek · $29