apache/cassandra · error · IllegalArgumentException

Unknown verb id + id

Error message

Unknown verb id + id

What it means

Verb.fromId(id) decodes a wire message's verb id via the idToVerbMap (or the custom map). If the id is negative, out of range, or unregistered on this node's version, there is no matching Verb and IllegalArgumentException is thrown, failing message deserialization.

Solutions

  1. Align cluster versions so all nodes use the same Cassandra build/verb registry before restarting messaging.
  2. Verify no custom verb patches are applied to only some nodes; apply consistently and restart the sender.
  3. Check for network corruption if ids are consistently garbage (rare); inspect logs for the offending id value.

Example fix

// before
Verb verb = Verb.fromId(buffer.readInt()); // may throw on unknown id
// after
if (id >= 0 && id < Verb.idToVerbMapSize()) { Verb verb = Verb.fromId(id); } else { log.warn("dropping unknown verb id", id); }
Defensive patterns

Strategy: try-catch

Validate before calling

boolean isKnownVerb(int id) { return id >= 0 && id < Verb.idMapLength(); }

Try / catch

try { Verb v = Verb.fromId(id); } catch (IllegalArgumentException e) { logger.warn("Unknown verb id {} from {} - dropping message (version mismatch?)", id, from); metrics.unknownVerb.mark(); }

Prevention

When it happens

Trigger: Receiving an internode message whose verb id byte does not exist in the local Verb table — e.g. a message sent by a newer/older node with different verb ids, or corrupted frame data.

Common situations: Rolling upgrades/downgrades where verb sets differ; mixed-version clusters with incompatible patches; a node that failed to register a custom verb the peer sends.

Understand the failure class

Background: Invalid enum value errors: "Unknown type", "Invalid scope", "must be one of" — when a string is not on the library's allowed list — this error's family across 23 libraries.

Related errors


AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10). Data as JSON: /api/errors/a298771bab680306. Report an issue: GitHub.

Appendix: source

Thrown at src/java/org/apache/cassandra/net/Verb.java:656

                    throw new AssertionError("Unsupported Verb Kind: " + v.kind + " for verb " + v);
            }
        }

        idToVerbMap = idMap;
        idToCustomVerbMap = customIdMap;
    }

    public static Verb fromId(int id)
    {
        Verb[] verbs = idToVerbMap;
        if (id >= minCustomId)
        {
            id = idForCustomVerb(id);
            verbs = idToCustomVerbMap;
        }
        Verb verb = id >= 0 && id < verbs.length ? verbs[id] : null;
        if (verb == null)
            throw new IllegalArgumentException("Unknown verb id " + id);
        return verb;
    }

    /**
     * calculate an id for a custom verb
     */
    private static int idForCustomVerb(int id)
    {
        return CUSTOM_VERB_START - id;
    }

    private static <A, B> IVersionedAsymmetricSerializer<A, B> accordEmbedded(AsymmetricVersionedSerializer<A, B, Version> delegate)
    {
        return AccordSerializers.embedded(Version.CLUSTER_SAFE_VERSION, delegate);
    }

    private static <A, B> IVersionedAsymmetricSerializer<A, B> accordEmbedded(AsymmetricUnversionedSerializer<A, B> delegate)
    {

View on GitHub (pinned to 88fd0f6a0e)