jacek-lewandowski commented on a change in pull request #1276: URL: https://github.com/apache/cassandra/pull/1276#discussion_r767699679
########## File path: test/distributed/org/apache/cassandra/distributed/test/SSTableGenerationTest.java ########## @@ -0,0 +1,177 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.cassandra.distributed.test; + +import java.io.IOException; +import java.util.Set; +import java.util.concurrent.ExecutionException; + +import org.junit.BeforeClass; +import org.junit.Test; + +import org.apache.cassandra.cql3.UntypedResultSet; +import org.apache.cassandra.db.Directories; +import org.apache.cassandra.db.Keyspace; +import org.apache.cassandra.db.SystemKeyspace; +import org.apache.cassandra.distributed.Cluster; +import org.apache.cassandra.distributed.shared.ClusterUtils; +import org.apache.cassandra.io.sstable.Descriptor; +import org.apache.cassandra.io.sstable.SequenceBasedSSTableUniqueIdentifier; +import org.apache.cassandra.io.sstable.UUIDBasedSSTableUniqueIdentifier; +import org.apache.cassandra.metrics.RestorableMeter; +import org.apache.cassandra.tools.SystemExitException; +import org.apache.cassandra.utils.UUIDGen; +import org.assertj.core.api.Assertions; +import org.assertj.core.data.Offset; + +import static org.apache.cassandra.cql3.QueryProcessor.executeInternal; +import static org.apache.cassandra.db.SystemKeyspace.LEGACY_SSTABLE_ACTIVITY; +import static org.apache.cassandra.db.SystemKeyspace.SSTABLE_ACTIVITY_V2; +import static org.apache.cassandra.distributed.shared.FutureUtils.waitOn; +import static org.assertj.core.api.Assertions.assertThat; + +public class SSTableGenerationTest extends TestBaseImpl Review comment: We can, though this test verifies what needs to be verified I think: - `testRestartWithUUIDEnabled` starts a node with new ids feature disabled, creates some sstables and stops the node, those sstables are verified to conform the old naming format; then the node is restarted, thus this is very similar to upgrading the node where there are existing sstables with old numbering - `testRestartWithUUIDDisabled` shows that we cannot disable the feature if we have existing sstables generated with UUID I can add scenario where we just start a node with the feature disabled, create some sstables and restart the node (keep the feature disabled), but this scenario is well covered by many other tests -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]

