Skip to content

Conversation

@jacek-lewandowski
Copy link
Contributor

No description provided.

Copy link
Contributor

@blambov blambov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Please create a new ticket to generalize this mechanism to handle other pieces of metadata that are only meaningful for the originating node.

@jacek-lewandowski jacek-lewandowski force-pushed the CASSANDRA-16619-4.0 branch 5 times, most recently from dc022b8 to 0cc6550 Compare May 4, 2021 09:10
- md, me, nb sstables
- Update version to nb, update MetadataSerializerTest
- add missing test cases in MetadataSerializerTest

Co-authored-by: Jakub Zytka <jakub.zytka@datastax.com>
Co-authored-by: Jacek Lewandowski <jacek.lewandowski@datastax.com>
}

if (!skippedSSTables.isEmpty()) {
logger.warn("Origin of {} sstables is unknown or doesn't match the local node; commitLogIntervals for them were ignored", skippedSSTables.size());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can get a big number here after upgrade. Perhaps it makes sense to add some info about that - that this is nothing to worry about?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm... I think I can add more information

hasCommitLogLowerBound = version.compareTo("mb") >= 0;
hasCommitLogIntervals = version.compareTo("mc") >= 0;
hasAccurateMinMax = version.compareTo("md") >= 0;
hasOriginatingHostId = version.matches("(m[e-z])|(n[b-z])");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

o* versions are good too ;)
Noone's gonna remember to change this if o is ever introduced/
I think we need to make some comparisons with version.compareTo("nb") >= 0 being the last

testMetricsWithStreamingToTwoNodes(true);
}

private int getNumberOfSSTables(Cluster cluster, int node) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

could you please elaborate what do these changes fix?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hehe... this is in-jvm distributed test. I assumed exact number of sstables in various stages of the test case. After adding that sentinel to commit log replayer, there is one extra sstable created because local host id is unknown. And it is unknown because the server is running in a kind of degraded mode (for speeding up tests, etc).

* </p>
*/
@Ignore
// @Ignore
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe we want this @Ignore back, once the serialization samples have been generated

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah yes, indeed


@Test
public void testMaReadMc() throws IOException
private void testVersions(String... versions) throws Throwable
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I propose testOldReadsNew name (and similarly for testOldReadsNewMVersions and testOldReadsNewNVersions). This is the crux of the test, but with the current name it's hidden in the very details of the implementation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

@blerer
Copy link
Contributor

blerer commented Jun 1, 2021

Merged manually

@blerer blerer closed this Jun 1, 2021
@jacek-lewandowski jacek-lewandowski deleted the CASSANDRA-16619-4.0 branch November 19, 2021 06:47
adelapena pushed a commit to adelapena/cassandra that referenced this pull request Feb 8, 2024
Optimize the `ChunkCache#invalidateFile` method by introducing a map that keeps track of the file to key set in the `ChunkCache`. The current solution is costly, as it iterates over the whole cache.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants