15
15
import os
16
16
import re
17
17
import time
18
- from functools import cached_property
19
18
20
19
from sdcm .sct_events import Severity
21
20
from sdcm .sct_events .system import TestFrameworkEvent
22
21
from sdcm .utils .common import skip_optional_stage
23
22
from sdcm .utils .decorators import optional_stage
24
23
from sdcm .utils .issues import SkipPerIssues
25
- from sdcm .utils .features import is_tablets_feature_enabled
26
24
27
25
DEFAULT_USER = "cassandra"
28
26
DEFAULT_USER_PASSWORD = "cassandra"
@@ -95,12 +93,6 @@ def assemble_and_run_all_stress_cmd_by_ks_names(self, stress_queue, stress_cmd,
95
93
}
96
94
self ._run_all_stress_cmds (stress_queue , params )
97
95
98
- @cached_property
99
- def tablets_enabled (self ):
100
- # is tablets feature enabled in Scylla configuration.
101
- with self .db_cluster .cql_connection_patient (self .db_cluster .nodes [0 ]) as session :
102
- return is_tablets_feature_enabled (session )
103
-
104
96
def _run_all_stress_cmds (self , stress_queue , params ):
105
97
stress_cmds = params ['stress_cmd' ]
106
98
if not isinstance (stress_cmds , list ):
@@ -117,7 +109,10 @@ def _run_all_stress_cmds(self, stress_queue, params):
117
109
# Due to an issue with scylla & cassandra-stress - we need to create the counter table manually
118
110
# also tablets doesn't yet support counters, so we skip the command and error about it
119
111
if 'counter_' in stress_cmd :
120
- if self .tablets_enabled and SkipPerIssues ('scylladb/scylladb#18180' , params = self .params ):
112
+ with self .db_cluster .nodes [0 ].remote_scylla_yaml () as scylla_yaml :
113
+ tablets_enabled = scylla_yaml .enable_tablets
114
+
115
+ if tablets_enabled and SkipPerIssues ('scylladb/scylladb#18180' , params = self .params ):
121
116
TestFrameworkEvent (severity = Severity .ERROR ,
122
117
source = self .__class__ .__name__ ,
123
118
source_method = '_run_all_stress_cmds' ,
0 commit comments