{"record":{"id":"23120aed0bfe4c80","repo":"apache/cassandra","slug":"unknown-table","errorCode":null,"errorMessage":"Unknown table","messagePattern":"Unknown table","errorType":"exception","errorClass":"UnknownTableException","httpStatus":null,"severity":"error","filePath":"src/java/org/apache/cassandra/service/accord/serializers/TableMetadatas.java","lineNumber":370,"sourceCode":"\n        @Override\n        public void serializeSelf(DataOutputPlus out) throws IOException\n        {\n            out.writeUnsignedVInt32(ids.length);\n            for (TableId id : ids)\n                id.serializeCompactComparable(out);\n        }\n\n        @Override\n        public TableMetadata deserialize(DataInputPlus in) throws IOException\n        {\n            if (ids.length == 1)\n                return metadatas[0];\n\n            int index = in.readUnsignedVInt32();\n            TableMetadata metadata = metadatas[index];\n            if (metadata == null)\n                throw new UnknownTableException(\"Unknown table\", ids[index]);\n            return metadata;\n        }\n\n        @Override\n        public long serializedSize(TableMetadata table)\n        {\n            if (ids.length == 1)\n                return 0;\n\n            int i = indexOf(table);\n            if (i < 0)\n                throw new IllegalStateException(\"TableMetadata for \" + table + \" not found in \" + this);\n            return TypeSizes.sizeofUnsignedVInt(indexOf(table));\n        }\n\n        @Override\n        public long serializedSelfSize()\n        {","sourceCodeStart":352,"sourceCodeEnd":388,"githubUrl":"https://github.com/apache/cassandra/blob/88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1/src/java/org/apache/cassandra/service/accord/serializers/TableMetadatas.java#L352-L388","documentation":"Thrown when deserializing a TableMetadatas payload: the table id read off the wire maps to a null slot in the decoded metadata array, meaning the peer referenced a table this node does not know about. It is raised as UnknownTableException to signal the Accord replication layer that a coordinator has knowledge of a table the local node lacks, typically during topology churn.","triggerScenarios":"Accord deserialize() reads an unsigned VInt index into the metadatas array and the slot is null because the serialized table id list contains a table id not present in this node's schema.","commonSituations":"Rolling upgrades or restarts where a node's schema is lagging behind the coordinator's; a table dropped on the coordinator but still referenced by in-flight Accord transactions on this node; schema disagreement across the cluster.","solutions":["Ensure schema agreement before running Accord workloads (check system_schema tables agree across nodes).","Force a schema refresh on the lagging node (nodetool resetlocalschema or re-running schema pull).","Retry the operation after the node catches up on schema; the transaction should be re-coordinated once the table metadata is known.","If the table was intentionally dropped, clear stale in-flight Accord state referencing the dropped table id."],"exampleFix":null,"handlingStrategy":"retry","validationCode":"// before coordinating Accord work, check schema agreement\nSet<String> schemas = nodes.stream().map(n -> fetchSchemaVersion(n)).collect(Collectors.toSet());\nif (schemas.size() > 1) throw new IllegalStateException(\"schema disagreement: \" + schemas);","typeGuard":null,"tryCatchPattern":"try {\n    TableMetadata metadata = serializer.deserialize(in, version);\n} catch (UnknownTableException e) {\n    logger.warn(\"Peer referenced unknown table {} - refreshing schema\", e.tableId);\n    Schema.instance.updateLocalSchema(); // then retry the operation\n}","preventionTips":["Wait for schema agreement after DDL before running Accord transactions","Use nodetool resetlocalschema on lagging nodes","Avoid dropping tables with in-flight Accord transactions","Keep the cluster on a single build during upgrades"],"tags":["serialization","accord","schema-disagreement"],"backgroundTag":"resource-not-found","analyzedSha":"88fd0f6a0eaed8943f05ac9e8f947882b8ddc8f1","analyzedAt":"2026-09-10T07:29:22.284Z","contentChangedAt":"2026-09-10T07:29:22.284Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}