Stefan Miklosovic created CASSANDRA-21133:
---------------------------------------------

             Summary: bin/sstableupgrade is not functionally on par with 
nodetool upgradesstables
                 Key: CASSANDRA-21133
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-21133
             Project: Apache Cassandra
          Issue Type: Improvement
            Reporter: Stefan Miklosovic


I am not sure if this is done on purpose or not but it seems to me that what I 
can achieve with nodetool version can not be achieved with bin version of 
SSTable upgrading.

Nodetool version enables a user to specify "-a" flag which will include 
SSTables even they are on the same version / format. 

{code}
    @Option(paramLabel = "include_all",
            names = { "-a", "--include-all-sstables" },
            description = "Use -a to include all sstables, even those already 
on the current version")
    private boolean includeAll = false;

/// and later 

        return performSSTableRewrite(cfs, (sstable) -> {
            // Skip if descriptor version matches current version
            if (skipIfCurrentVersion && 
sstable.descriptor.version.equals(sstable.descriptor.getFormat().getLatestVersion()))
                return false;

{code}

On the other hand, bin/sstableupgrade does not make this possible:

{code}
                    SSTableReader sstable = 
SSTableReader.openNoValidation(entry.getKey(), components, cfs);
                    if 
(sstable.descriptor.version.equals(DatabaseDescriptor.getSelectedSSTableFormat().getLatestVersion()))
                    {
                        sstable.selfRef().release();
                        continue;
                    }
                    readers.add(sstable);
{code}

This might be viewed as a functional gap / discrepancy between these two. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to