@@ -251,14 +251,19 @@ def test_read_from_bootstrapped_node(self):
251251 cluster = self .cluster
252252 cluster .set_environment_variable ('CASSANDRA_TOKEN_PREGENERATION_DISABLED' , 'True' )
253253 cluster .populate (3 )
254+ if cluster .version () <= '5.0' :
255+ # Nodes need to be started one by one pre-TCM, not all at once. See CASSANDRA-19097
256+ cluster .nodelist ()[0 ].start (wait_for_binary_proto = True )
257+ cluster .nodelist ()[1 ].start (wait_for_binary_proto = True )
258+ cluster .nodelist ()[2 ].start (wait_for_binary_proto = True )
254259 cluster .start ()
255260
256261 node1 = cluster .nodes ['node1' ]
257262 node1 .stress (['write' , 'n=10K' , 'no-warmup' , '-rate' , 'threads=8' , '-schema' , 'replication(factor=2)' ])
258263
259264 session = self .patient_cql_connection (node1 )
260265 stress_table = 'keyspace1.standard1'
261- query = SimpleStatement ("SELECT * FROM %s" % (stress_table ), consistency_level = ConsistencyLevel . ALL )
266+ query = SimpleStatement ("SELECT * FROM %s" % (stress_table ))
262267 original_rows = list (session .execute (query ))
263268
264269 node4 = new_node (cluster )
@@ -518,7 +523,12 @@ def test_manual_bootstrap(self):
518523 """
519524 cluster = self .cluster
520525 cluster .set_environment_variable ('CASSANDRA_TOKEN_PREGENERATION_DISABLED' , 'True' )
521- cluster .populate (2 ).start ()
526+ cluster .populate (2 )
527+ if cluster .version () <= '5.0' :
528+ # Nodes need to be started one by one pre-TCM, not all at once. See CASSANDRA-19097
529+ cluster .nodelist ()[0 ].start (wait_for_binary_proto = True )
530+ cluster .nodelist ()[1 ].start (wait_for_binary_proto = True )
531+ cluster .start ()
522532 (node1 , node2 ) = cluster .nodelist ()
523533
524534 node1 .stress (['write' , 'n=1K' , 'no-warmup' , '-schema' , 'replication(factor=2)' ,
@@ -527,7 +537,7 @@ def test_manual_bootstrap(self):
527537 session = self .patient_exclusive_cql_connection (node2 )
528538 stress_table = 'keyspace1.standard1'
529539
530- query = SimpleStatement ("SELECT * FROM %s" % stress_table , consistency_level = ConsistencyLevel . ALL )
540+ query = SimpleStatement ("SELECT * FROM %s" % stress_table )
531541 original_rows = list (session .execute (query ))
532542
533543 # Add a new node
@@ -620,6 +630,11 @@ def _wiped_node_cannot_join_test(self, gently):
620630 cluster = self .cluster
621631 cluster .set_environment_variable ('CASSANDRA_TOKEN_PREGENERATION_DISABLED' , 'True' )
622632 cluster .populate (3 )
633+ if cluster .version () <= '5.0' :
634+ # Nodes need to be started one by one pre-TCM, not all at once. See CASSANDRA-19097
635+ cluster .nodelist ()[0 ].start (wait_for_binary_proto = True )
636+ cluster .nodelist ()[1 ].start (wait_for_binary_proto = True )
637+ cluster .nodelist ()[2 ].start (wait_for_binary_proto = True )
623638 cluster .start ()
624639
625640 stress_table = 'keyspace1.standard1'
@@ -629,7 +644,7 @@ def _wiped_node_cannot_join_test(self, gently):
629644 node1 .stress (['write' , 'n=10K' , 'no-warmup' , '-rate' , 'threads=8' ])
630645
631646 session = self .patient_cql_connection (node1 )
632- query = SimpleStatement ("SELECT * FROM {}" .format (stress_table ), consistency_level = ConsistencyLevel . ALL )
647+ query = SimpleStatement ("SELECT * FROM {}" .format (stress_table ))
633648 original_rows = list (session .execute (query ))
634649
635650 # Add a new node, bootstrap=True ensures that it is not a seed
@@ -655,6 +670,11 @@ def test_decommissioned_wiped_node_can_join(self):
655670 cluster = self .cluster
656671 cluster .set_environment_variable ('CASSANDRA_TOKEN_PREGENERATION_DISABLED' , 'True' )
657672 cluster .populate (3 )
673+ if cluster .version () <= '5.0' :
674+ # Nodes need to be started one by one pre-TCM, not all at once. See CASSANDRA-19097
675+ cluster .nodelist ()[0 ].start (wait_for_binary_proto = True )
676+ cluster .nodelist ()[1 ].start (wait_for_binary_proto = True )
677+ cluster .nodelist ()[2 ].start (wait_for_binary_proto = True )
658678 cluster .start ()
659679
660680 stress_table = 'keyspace1.standard1'
@@ -664,7 +684,7 @@ def test_decommissioned_wiped_node_can_join(self):
664684 node1 .stress (['write' , 'n=10K' , 'no-warmup' , '-rate' , 'threads=8' ])
665685
666686 session = self .patient_cql_connection (node1 )
667- query = SimpleStatement ("SELECT * FROM {}" .format (stress_table ), consistency_level = ConsistencyLevel . ALL )
687+ query = SimpleStatement ("SELECT * FROM {}" .format (stress_table ))
668688 original_rows = list (session .execute (query ))
669689
670690 # Add a new node, bootstrap=True ensures that it is not a seed
0 commit comments