apache/cassandra · error · IORuntimeException

Unsupported record type field

Error message

Unsupported record type field [${type}] - supported record types are [${SINGLE_QUERY}, ${BATCH}]

What it means

Dump.dump reads the record's TYPE field and requires it to equal FullQueryLogger.SINGLE_QUERY or FullQueryLogger.BATCH; any other value triggers this IORuntimeException. It is the string-level type validation that precedes switch-based dispatch of the record.

Solutions

  1. Verify the input is a full-query-log file/directory
  2. Re-capture or restore the log from a clean source
  3. Upgrade the tool if the log was written by a newer Cassandra with new record types
Defensive patterns

Strategy: validation

Try / catch

try { dump(file); } catch (IORuntimeException e) { if (e.getMessage().startsWith("Unsupported record type field")) { log.warn("file is not a full query log: " + file); } else throw e; }

Prevention

When it happens

Trigger: A record in the dumped log has a TYPE string other than 'single_query' or 'batch' — corrupted wire data or a non-FQL Chronicle file.

Common situations: Feeding unrelated Chronicle Queue files to fqltool dump; bit rot in stored logs; files from other Cassandra components.

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/19eaf270e2f12746. Report an issue: GitHub.

Appendix: source

Thrown at tools/fqltool/src/org/apache/cassandra/fqltool/commands/Dump.java:92

    public static void dump(List<String> arguments, String rollCycle, boolean follow)
    {
        StringBuilder sb = new StringBuilder();
        ReadMarshallable reader = wireIn ->
        {
            sb.setLength(0);

            int version = wireIn.read(BinLog.VERSION).int16();
            if (version > FullQueryLogger.CURRENT_VERSION)
            {
                throw new IORuntimeException("Unsupported record version [" + version
                                             + "] - highest supported version is [" + FullQueryLogger.CURRENT_VERSION + ']');
            }

            String type = wireIn.read(BinLog.TYPE).text();
            if (!FullQueryLogger.SINGLE_QUERY.equals((type)) && !FullQueryLogger.BATCH.equals((type)))
            {
                throw new IORuntimeException("Unsupported record type field [" + type
                                             + "] - supported record types are [" + FullQueryLogger.SINGLE_QUERY + ", " + FullQueryLogger.BATCH + ']');
            }

            sb.append("Type: ")
              .append(type)
              .append(System.lineSeparator());

            long queryStartTime = wireIn.read(FullQueryLogger.QUERY_START_TIME).int64();
            sb.append("Query start time: ")
              .append(queryStartTime)
              .append(System.lineSeparator());

            int protocolVersion = wireIn.read(FullQueryLogger.PROTOCOL_VERSION).int32();
            sb.append("Protocol version: ")
              .append(protocolVersion)
              .append(System.lineSeparator());

            QueryOptions options =

View on GitHub (pinned to 88fd0f6a0e)