{"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/c31c9215e131f8c17e79f8901b48c13ee6aa8e7a/clients/src/main/java/org/apache/kafka/clients/admin/StreamsGroupTopologyDescriptionStatus.java#L64-L85","documentation":"Thrown by StreamsGroupTopologyDescriptionStatus.forId(byte) when deserializing a Streams group topology status from the broker and the wire id does not match any defined enum value. The enum maps broker-reported topology description states to client-side constants; an unknown id means the client cannot interpret a status the broker sent. This almost always indicates a broker/client version skew where a newer broker introduced a status id the older client does not recognize.","triggerScenarios":"Deserialization of a DescribeStreamsGroupResponse (AdminClient.describeStreamsGroups) where the broker returns a topology description status byte not present in the client's compiled enum. Internal: the forId loop at line 77 falls through without a match.","commonSituations":"Rolling upgrade of a Kafka cluster to a version that adds new StreamsGroupTopologyDescriptionStatus values while client applications still run an older client library; mixed-version clusters during upgrade windows; brokers with experimental/new Streams group features enabled.","solutions":["Upgrade the Kafka client library to match (or exceed) the broker version that introduced the new status id.","Pin the broker feature to a version compatible with the deployed client until clients are upgraded.","Check the broker logs/release notes for the StreamsGroupTopologyDescriptionStatus enum to identify the new id and its meaning."],"exampleFix":"// before: client older than broker\n<dependency>\n  <groupId>org.apache.kafka</groupId>\n  <artifactId>kafka-clients</artifactId>\n  <version>3.7.0</version>\n</dependency>\n\n// after: align client with broker\n<dependency>\n  <groupId>org.apache.kafka</groupId>\n  <artifactId>kafka-clients</artifactId>\n  <version>3.9.0</version> <!-- match broker version -->\n</dependency>","handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"// StreamsGroupTopologyDescriptionStatus.forId is driven by broker wire data the user cannot validate ahead of time.\nStreamsGroupTopologyDescriptionStatus status;\ntry {\n    status = StreamsGroupTopologyDescriptionStatus.forId(rawId);\n} catch (IllegalArgumentException e) {\n    log.warn(\"Broker returned unknown topology description status id {} - client/broker version skew likely\", rawId);\n    status = StreamsGroupTopologyDescriptionStatus.ERROR; // safe fallback\n}","preventionTips":["This error is caused by client/broker version mismatch - the broker sent a status id newer than this client knows.","Keep client and broker versions aligned; bump the client jar when upgrading brokers.","Do not call forId yourself in application code - consume StreamsGroupDescription.topologyDescriptionStatus() which is already parsed."],"tags":["admin-api","streams","wire-protocol","version-mismatch","deserialization","java"],"analyzedSha":"c31c9215e131f8c17e79f8901b48c13ee6aa8e7a","analyzedAt":"2026-08-03T12:34:05.770Z","schemaVersion":2}