{"record":{"id":"452fa74abc25605d","repo":"apache/kafka","slug":"unknown-topology-description-status-id-id","errorCode":null,"errorMessage":"Unknown topology description status id: {id}","messagePattern":"Unknown topology description status id: (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"clients/src/main/java/org/apache/kafka/clients/admin/StreamsGroupTopologyDescriptionStatus.java","lineNumber":82,"sourceCode":"     */\n    public byte id() {\n        return id;\n    }\n\n    /**\n     * Returns the status corresponding to the given wire identifier.\n     *\n     * @param id the wire identifier.\n     * @return the matching status.\n     * @throws IllegalArgumentException if the identifier is unknown.\n     */\n    public static StreamsGroupTopologyDescriptionStatus forId(final byte id) {\n        for (final StreamsGroupTopologyDescriptionStatus status : values()) {\n            if (status.id == id) {\n                return status;\n            }\n        }\n        throw new IllegalArgumentException(\"Unknown topology description status id: \" + id);\n    }\n}\n","sourceCodeStart":64,"sourceCodeEnd":85,"githubUrl":"https://github.com/apache/kafka/blob/996fb4585aa1bcc8980b0e1b8d6b168b986cd979/clients/src/main/java/org/apache/kafka/clients/admin/StreamsGroupTopologyDescriptionStatus.java#L64-L85","documentation":"Thrown by StreamsGroupTopologyDescriptionStatus.forId(byte) when no enum constant matches the wire id received in a StreamsGroupDescribe response. This indicates the broker sent a topology description status value unknown to this client version. The enum is part of the consumer protocol surface and only grows when new statuses are added in newer broker versions.","triggerScenarios":"Calling StreamsGroupTopologyDescriptionStatus.forId with a byte value not among the declared enum ids. Encountered during deserialization of a StreamsGroupDescribeResponse from a newer broker that introduced a new status value.","commonSituations":"Client older than broker; rolling upgrade where the client hits a controller/broker that already speaks a newer protocol; corrupt or unexpected response from a misbehaving broker.","solutions":["Upgrade the Kafka client library to match (or exceed) the broker version.","Pin the broker's inter-broker and client-facing API versions to a range the client supports.","Catch IllegalArgumentException during describeStreamsGroups and report an unsupported-version diagnostic."],"exampleFix":"// before\nStreamsGroupDescription desc = admin.describeStreamsGroups(List.of(group))\n    .all().get().get(group);\n\n// after\ntry {\n    StreamsGroupDescription desc = admin.describeStreamsGroups(List.of(group))\n        .all().get().get(group);\n} catch (ExecutionException e) {\n    if (e.getCause() instanceof IllegalArgumentException\n        && e.getCause().getMessage().contains(\"Unknown topology description status id\")) {\n        throw new IllegalStateException(\"Client version too old for broker; upgrade kafka-clients\", e);\n    }\n    throw e;\n}","handlingStrategy":"try-catch","validationCode":"// Cannot pre-validate wire bytes; ensure client version >= broker version\nassert clientVersionIsAtLeast(brokerVersion) : \"upgrade kafka-clients\";","typeGuard":null,"tryCatchPattern":"try {\n    return admin.describeStreamsGroups(groups).all().get();\n} catch (ExecutionException e) {\n    if (e.getCause() instanceof IllegalArgumentException\n        && e.getCause().getMessage().contains(\"Unknown topology description status id\")) {\n        throw new IllegalStateException(\"Upgrade kafka-clients to match broker\", e);\n    }\n    throw e;\n}","preventionTips":["Keep the kafka-clients version aligned with (or ahead of) the broker cluster version.","Pin api.version.request.enabled and use a known supported API version range.","Test describeStreamsGroups against a broker matching production during CI."],"tags":["admin-client","streams","wire-protocol","illegal-argument","version-mismatch"],"backgroundTag":null,"analyzedSha":"996fb4585aa1bcc8980b0e1b8d6b168b986cd979","analyzedAt":"2026-08-11T22:03:28.655Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}