Skip to content

Commit

Permalink
LegacyLayout does not have same behavior as 2.x when handling unknown…
Browse files Browse the repository at this point in the history
… column names (CASSANDRA-15081)
  • Loading branch information
Cameron Zemek committed Oct 23, 2020
1 parent 9bb7401 commit 8e259f3
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/java/org/apache/cassandra/db/LegacyLayout.java
Original file line number Diff line number Diff line change
Expand Up @@ -1179,10 +1179,10 @@ public static LegacyAtom readLegacyAtom(CFMetaData metadata, DataInputPlus in, b
// but we don't do this here and re-throw the exception because the calling code sometimes has to know
// about this happening. This does mean code calling this method should handle this case properly.
if (!metadata.ksName.equals(SchemaConstants.SYSTEM_KEYSPACE_NAME) && metadata.getDroppedColumnDefinition(e.columnName) == null)
throw new IllegalStateException(String.format("Got cell for unknown column %s in sstable of %s.%s: " +
"This suggest a problem with the schema which doesn't list " +
"this column. Even if that column was dropped, it should have " +
"been listed as such", metadata.ksName, metadata.cfName, UTF8Type.instance.compose(e.columnName)), e);
logger.warn(String.format("Got cell for unknown column %s in sstable of %s.%s: " +
"This suggest a problem with the schema which doesn't list " +
"this column. Even if that column was dropped, it should have " +
"been listed as such", metadata.ksName, metadata.cfName, UTF8Type.instance.compose(e.columnName)), e);

throw e;
}
Expand Down

0 comments on commit 8e259f3

Please sign in to comment.