{
  "id": "api/grpc-resource-exhausted-rate-limit",
  "signature": "gRPC error: RESOURCE_EXHAUSTED: rate limit exceeded",
  "signature_zh": "gRPC 错误：RESOURCE_EXHAUSTED：超出速率限制",
  "regex": "gRPC\\s+error:\\s+RESOURCE_EXHAUSTED:\\s+rate\\s+limit\\s+exceeded",
  "domain": "api",
  "category": "resource_error",
  "subcategory": null,
  "root_cause": "The gRPC server rejected the request because the client exceeded the configured rate limit, often due to aggressive retries or high concurrency.",
  "root_cause_type": "generic",
  "root_cause_zh": "gRPC 服务器因客户端超出配置的速率限制而拒绝请求，通常由于激进的重试或高并发导致。",
  "versions": [
    {
      "version": "gRPC 1.62.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Envoy 1.29.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Istio 1.20.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "gRPC-Go 1.62.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Without exponential backoff, retries are sent immediately, consuming more quota and causing cascading failures.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Removing rate limits exposes the server to abuse and performance degradation.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Rate limits are often enforced at the service level regardless of protocol; REST endpoints may have similar or stricter limits.",
      "fail_rate": 0.6,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Implement exponential backoff with jitter in the gRPC client. Example in Go: `backoff := grpc.WithBackoffMaxDelay(5 * time.Second); conn, err := grpc.Dial(target, backoff)`.",
      "success_rate": 0.85,
      "how": "Implement exponential backoff with jitter in the gRPC client. Example in Go: `backoff := grpc.WithBackoffMaxDelay(5 * time.Second); conn, err := grpc.Dial(target, backoff)`.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Reduce concurrency by limiting the number of in-flight gRPC streams using a semaphore or connection pool. For example, use a channel-based worker pool in Go.",
      "success_rate": 0.8,
      "how": "Reduce concurrency by limiting the number of in-flight gRPC streams using a semaphore or connection pool. For example, use a channel-based worker pool in Go.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Contact the API provider to request a higher rate limit or check the Retry-After header in the gRPC trailing metadata for a suggested wait time.",
      "success_rate": 0.7,
      "how": "Contact the API provider to request a higher rate limit or check the Retry-After header in the gRPC trailing metadata for a suggested wait time.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Implement exponential backoff with jitter in the gRPC client. Example in Go: `backoff := grpc.WithBackoffMaxDelay(5 * time.Second); conn, err := grpc.Dial(target, backoff)`.",
    "Reduce concurrency by limiting the number of in-flight gRPC streams using a semaphore or connection pool. For example, use a channel-based worker pool in Go.",
    "Contact the API provider to request a higher rate limit or check the Retry-After header in the gRPC trailing metadata for a suggested wait time."
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://grpc.github.io/grpc/core/md_doc_statuscodes.html",
  "official_doc_section": null,
  "error_code": "RESOURCE_EXHAUSTED",
  "verification_tier": "ai_generated",
  "confidence": 0.88,
  "fix_success_rate": 0.82,
  "resolvable": "partial",
  "first_seen": "2024-06-10",
  "last_confirmed": "2024-06-01",
  "last_updated": "2025-02-05",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}