[ https://issues.apache.org/jira/browse/IGNITE-22050?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17846943#comment-17846943 ]
Aleksandr Polovtsev commented on IGNITE-22050: ---------------------------------------------- Here's the original problem reproducer, it should also be checked during the ticket development and/or converted into a test: {code:java} public class GcIssueExample extends ClusterPerClassIntegrationTest { @Override protected int initialNodes() { return 1; } @Override protected void configureInitParameters(InitParametersBuilder builder) { builder.clusterConfiguration("{" + "gc.lowWatermark.dataAvailabilityTime: 1000,\n" + "gc.lowWatermark.updateFrequency: 3000\n" + "}"); } @Test public void test() throws Exception { sql("CREATE ZONE IF NOT EXISTS zone_test WITH storage_profiles='default_aimem'"); sql("CREATE TABLE IF NOT EXISTS db1 (id int, f_name varchar, l_name varchar, str varchar," + " PRIMARY KEY (id)) WITH PRIMARY_ZONE='ZONE_TEST';"); int numberOfRecords = 10; // int numberOfUpdates = 400; // Works fine // int numberOfUpdates = 500; // Works fine // int numberOfUpdates = 600; // Doesn't work int numberOfUpdates = 1000; // Doesn't work for(int i = 0; i < numberOfRecords; i++) { sql(format("INSERT INTO db1 (id, f_name, l_name, str) VALUES ({}, 'John', 'Doe', 'test');", i)); for (int j = 0; j < numberOfUpdates; j++ ) { sql(format("UPDATE db1 SET str = 'Some test data version {}' WHERE id = {}", j, i)); } } } } {code} > Data structures don't clear partId of reused page > ------------------------------------------------- > > Key: IGNITE-22050 > URL: https://issues.apache.org/jira/browse/IGNITE-22050 > Project: Ignite > Issue Type: Bug > Reporter: Ivan Bessonov > Assignee: Aleksandr Polovtsev > Priority: Major > Labels: ignite-3 > Fix For: 3.0.0-beta2 > > Time Spent: 20m > Remaining Estimate: 0h > > In current implementation we use a single reuse list for all partitions in > aimem storage engine. > That works fine in Ignite 2, but here in Ignite 3 we implemented a > "partitilnless link" format for eliminating 2 bytes, that indicate partition > number, from the data in pages. This means that if allocator provided the > structure with the page from partition X, but the structure itself represents > partition Y, we will lose the "X" in the process and next time will try > accessing the page by the pageId that has Y encoded in it. This would lead to > pageId mismatch. > We have several options here. > * ignore mismatched partitions > * get rid of partitionless pageIds > * fix the allocator, so that it would change partition Id upon allocation > Ideally, we should go with the 3rd option. It requires some slight changes in > internal data structure API, so that we would pass the required partitionId > directly into the allocator (reuse list). This is a little bit excessive at > first sight, but seems more appropriate in a long run. Ignite 2 pageIds are > all messed up inside of structures, we can fix that. -- This message was sent by Atlassian Jira (v8.20.10#820010)