3535 group_keys_by_replica , NO_VALID_REPLICA )
3636from cassandra .protocol import QueryMessage , ProtocolHandler
3737from cassandra .util import SortedSet
38+ from ccmlib .scylla_cluster import ScyllaCluster
3839
3940from tests .integration import (get_cluster , use_singledc , PROTOCOL_VERSION , execute_until_pass ,
4041 BasicSegregatedKeyspaceUnitTestCase , BasicSharedKeyspaceUnitTestCase ,
4546 lessthancass40 ,
4647 TestCluster , requires_java_udf , requires_composite_type ,
4748 requires_collection_indexes , SCYLLA_VERSION , xfail_scylla , xfail_scylla_version_lt ,
48- requirescompactstorage )
49+ requirescompactstorage , scylla_only , EVENT_LOOP_MANAGER )
4950
5051from tests .util import wait_until , assertRegex , assertDictEqual , assertListEqual , assert_startswith_diff
5152
@@ -217,6 +218,7 @@ def get_table_metadata(self):
217218 self .cluster .refresh_table_metadata (self .keyspace_name , self .function_table_name )
218219 return self .cluster .metadata .keyspaces [self .keyspace_name ].tables [self .function_table_name ]
219220
221+ @pytest .mark .xfail (reason = "test not stable on Cassandra" , condition = EVENT_LOOP_MANAGER == "asyncio" and SCYLLA_VERSION is None , strict = False )
220222 def test_basic_table_meta_properties (self ):
221223 create_statement = self .make_create_statement (["a" ], [], ["b" , "c" ])
222224 self .session .execute (create_statement )
@@ -577,6 +579,7 @@ def test_non_size_tiered_compaction(self):
577579 assert "max_threshold" not in cql
578580
579581 @requires_java_udf
582+ @pytest .mark .xfail (reason = "test not stable on Cassandra" , condition = EVENT_LOOP_MANAGER == "asyncio" and SCYLLA_VERSION is None , strict = False )
580583 def test_refresh_schema_metadata (self ):
581584 """
582585 test for synchronously refreshing all cluster metadata
@@ -1066,6 +1069,7 @@ def test_metadata_pagination(self):
10661069 self .cluster .refresh_schema_metadata ()
10671070 assert len (self .cluster .metadata .keyspaces [self .keyspace_name ].tables ) == 12
10681071
1072+ @pytest .mark .xfail (reason = "test not stable on Cassandra" , condition = EVENT_LOOP_MANAGER == "asyncio" and SCYLLA_VERSION is None , strict = False )
10691073 def test_metadata_pagination_keyspaces (self ):
10701074 """
10711075 test for covering
@@ -1269,14 +1273,15 @@ def test_already_exists_exceptions(self):
12691273 cluster .shutdown ()
12701274
12711275 @local
1272- @pytest .mark .xfail (reason = 'AssertionError: \' RAC1\' != \' r1\' - probably a bug in driver or in Scylla' )
12731276 def test_replicas (self ):
12741277 """
12751278 Ensure cluster.metadata.get_replicas return correctly when not attached to keyspace
12761279 """
12771280 if murmur3 is None :
12781281 raise unittest .SkipTest ('the murmur3 extension is not available' )
12791282
1283+ is_scylla = isinstance (get_cluster (), ScyllaCluster )
1284+
12801285 cluster = TestCluster ()
12811286 assert cluster .metadata .get_replicas ('test3rf' , 'key' ) == []
12821287
@@ -1285,7 +1290,7 @@ def test_replicas(self):
12851290 assert list (cluster .metadata .get_replicas ('test3rf' , b'key' )) != []
12861291 host = list (cluster .metadata .get_replicas ('test3rf' , b'key' ))[0 ]
12871292 assert host .datacenter == 'dc1'
1288- assert host .rack == ' r1'
1293+ assert host .rack == ( 'RAC1' if is_scylla else ' r1')
12891294 cluster .shutdown ()
12901295
12911296 def test_token_map (self ):
@@ -1325,6 +1330,8 @@ def test_token(self):
13251330 cluster .shutdown ()
13261331
13271332
1333+ # this is scylla only, since the metadata timeout feature doesn't cover peers_v2 queries that is used by cassandra
1334+ @scylla_only
13281335class TestMetadataTimeout :
13291336 """
13301337 Test of TokenMap creation and other behavior.
0 commit comments