Uploaded image for project: 'Apache Cassandra'
  1. Apache Cassandra
  2. CASSANDRA-4752

Drop keyspace causes schema disagreement

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Normal
    • Resolution: Fixed
    • 1.1.6
    • None
    • None
    • Normal

    Description

      The fix for CASSANDRA-4698 introduced a bug whereby when drop keyspace is issued a schema disagreement immediately occurs. This seems to be because the

      ColumnFamily cf = ColumnFamily.create(modification.getValue().metadata());

      in RowMutation.deserializeFixingTimestamps does not preserve deletion info for the cf in the modification. In most cases, this doesn't cause a problem, but for a drop keyspace modification, there are no columns in the cf, so the deletion info is effectively lost leading to an incorrect digest being created and ultimately a schema disagreement.

      Replacing the create with cloneMeShallow does preserve the deletion info and avoids the schema disagreement issue.

      Attachments

        1. 0001-CASSANDRA-4752.txt
          1 kB
          Sam Tunnicliffe
        2. 4752-v2.txt
          1 kB
          Jonathan Ellis

        Activity

          People

            samt Sam Tunnicliffe
            samt Sam Tunnicliffe
            Sam Tunnicliffe
            Jonathan Ellis
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: