{
  "id": "kafka/coordinator-load-in-progress",
  "signature": "org.apache.kafka.common.errors.CoordinatorLoadInProgressException: The coordinator is loading and cannot process requests",
  "signature_zh": "org.apache.kafka.common.errors.CoordinatorLoadInProgressException: 协调器正在加载，无法处理请求",
  "regex": "CoordinatorLoadInProgressException.*coordinator is loading",
  "domain": "kafka",
  "category": "runtime_error",
  "subcategory": null,
  "root_cause": "Group or transaction coordinator is still loading state from internal topics (e.g., __consumer_offsets) after a leader election or broker restart.",
  "root_cause_type": "generic",
  "root_cause_zh": "在领导者选举或代理重启后，组或事务协调器仍从内部主题（如__consumer_offsets）加载状态。",
  "versions": [
    {
      "version": "Kafka 3.3.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Kafka 3.4.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": "Restart the consumer application immediately",
      "why_fails": "Consumer restart does not speed up coordinator loading; it only retries the same request.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    },
    {
      "action": "Delete __consumer_offsets topic to reset state",
      "why_fails": "Deleting internal topics corrupts the cluster and causes data loss for all consumer groups.",
      "fail_rate": 0.99,
      "condition": "",
      "sources": []
    },
    {
      "action": "Reduce offsets.topic.num.partitions to 1",
      "why_fails": "Changing partition count requires cluster restart and does not fix loading speed.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Wait for coordinator to finish loading; check broker logs for 'Finished loading offsets from __consumer_offsets'.\nCommand to monitor:\nkafka-consumer-groups --bootstrap-server localhost:9092 --group my-group --describe --members --verbose\nIf loading takes too long, increase offsets.load.buffer.size in broker config:\necho \"offsets.load.buffer.size=10485760\" >> config/server.properties\nkafka-server-start.sh config/server.properties",
      "success_rate": 0.85,
      "how": "Wait for coordinator to finish loading; check broker logs for 'Finished loading offsets from __consumer_offsets'.\nCommand to monitor:\nkafka-consumer-groups --bootstrap-server localhost:9092 --group my-group --describe --members --verbose\nIf loading takes too long, increase offsets.load.buffer.size in broker config:\necho \"offsets.load.buffer.size=10485760\" >> config/server.properties\nkafka-server-start.sh config/server.properties",
      "condition": "",
      "sources": []
    },
    {
      "action": "Use exponential backoff in consumer retry logic to avoid overwhelming the coordinator.\nCode example:\nint retries = 0;\nwhile (retries < 5) {\n  try {\n    consumer.poll(Duration.ofMillis(1000));\n    break;\n  } catch (CoordinatorLoadInProgressException e) {\n    Thread.sleep((long) Math.pow(2, retries) * 1000);\n    retries++;\n  }\n}",
      "success_rate": 0.8,
      "how": "Use exponential backoff in consumer retry logic to avoid overwhelming the coordinator.\nCode example:\nint retries = 0;\nwhile (retries < 5) {\n  try {\n    consumer.poll(Duration.ofMillis(1000));\n    break;\n  } catch (CoordinatorLoadInProgressException e) {\n    Thread.sleep((long) Math.pow(2, retries) * 1000);\n    retries++;\n  }\n}",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Wait for coordinator to finish loading; check broker logs for 'Finished loading offsets from __consumer_offsets'.\nCommand to monitor:\nkafka-consumer-groups --bootstrap-server localhost:9092 --group my-group --describe --members --verbose\nIf loading takes too long, increase offsets.load.buffer.size in broker config:\necho \"offsets.load.buffer.size=10485760\" >> config/server.properties\nkafka-server-start.sh config/server.properties",
    "Use exponential backoff in consumer retry logic to avoid overwhelming the coordinator.\nCode example:\nint retries = 0;\nwhile (retries < 5) {\n  try {\n    consumer.poll(Duration.ofMillis(1000));\n    break;\n  } catch (CoordinatorLoadInProgressException e) {\n    Thread.sleep((long) Math.pow(2, retries) * 1000);\n    retries++;\n  }\n}"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://kafka.apache.org/documentation/#coordinator",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.88,
  "fix_success_rate": 0.85,
  "resolvable": "true",
  "first_seen": "2023-08-20",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}