{
  "id": "kafka/consumer-fetch-timeout",
  "signature": "org.apache.kafka.common.errors.FetchTimeoutException: Fetch request timed out after 30000 ms for partition my-topic-0",
  "signature_zh": "org.apache.kafka.common.errors.FetchTimeoutException：分区my-topic-0的获取请求在30000毫秒后超时",
  "regex": "FetchTimeoutException.*timed out after \\d+ ms",
  "domain": "kafka",
  "category": "network_error",
  "subcategory": null,
  "root_cause": "The consumer's fetch request to the broker exceeded the configured timeout due to network congestion, broker overload, or a slow partition leader.",
  "root_cause_type": "generic",
  "root_cause_zh": "由于网络拥塞、代理过载或分区领导者缓慢，消费者对代理的获取请求超过了配置的超时时间。",
  "versions": [
    {
      "version": "kafka 3.0.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "kafka 3.3.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "kafka 3.5.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "This only masks the timeout and can lead to increased consumer latency and backlog, without fixing the underlying network or broker issue.",
      "fail_rate": 0.4,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Restarting re-establishes the connection but does not resolve persistent network or broker load issues; the timeout will recur.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Increase the broker's 'fetch.purgatory.purge.interval.requests' and tune 'num.network.threads' to handle more concurrent fetch requests, reducing queue delays.",
      "success_rate": 0.8,
      "how": "Increase the broker's 'fetch.purgatory.purge.interval.requests' and tune 'num.network.threads' to handle more concurrent fetch requests, reducing queue delays.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Add a retry mechanism in the consumer with exponential backoff on FetchTimeoutException, and reduce fetch.min.bytes to allow smaller, faster responses.",
      "success_rate": 0.85,
      "how": "Add a retry mechanism in the consumer with exponential backoff on FetchTimeoutException, and reduce fetch.min.bytes to allow smaller, faster responses.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Increase the broker's 'fetch.purgatory.purge.interval.requests' and tune 'num.network.threads' to handle more concurrent fetch requests, reducing queue delays.",
    "Add a retry mechanism in the consumer with exponential backoff on FetchTimeoutException, and reduce fetch.min.bytes to allow smaller, faster responses."
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://kafka.apache.org/documentation/#consumerconfigs_fetch.max.wait.ms",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.82,
  "fix_success_rate": 0.75,
  "resolvable": "partial",
  "first_seen": "2023-11-20",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}