BUILD_ID | 504 |
BUILD_NUMBER | 504 |
BUILD_TAG | jenkins-CLUSTER-Workload_benchmarks_metrics-504 |
BUILD_URL | https://ci.wazuh.info/job/CLUSTER-Workload_benchmarks_metrics/504/ |
CI | true |
EXECUTOR_NUMBER | 1 |
JENKINS_URL | https://ci.wazuh.info/ |
JOB_NAME | CLUSTER-Workload_benchmarks_metrics |
NODE_NAME | EC2 (JenkinsCloud) - AL2_v.11.4_cluster_test (i-03f9f338c9af66695) |
Packages | {"pluggy": "0.13.1", "pytest": "6.2.2"} |
Platform | Linux-4.14.276-211.499.amzn2.x86_64-x86_64-with-glibc2.2.5 |
Plugins | {"html": "3.1.1", "metadata": "2.0.4", "testinfra": "5.0.0"} |
Python | 3.7.10 |
WORKSPACE | /home/ec2-user/workspace/CLUSTER-Workload_benchmarks_metrics |
Result | Test | Description | Duration | ||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
No results found. Try to check the filters | |||||||||||||||||||||||||||||||
Failed | performance/test_cluster/test_cluster_performance/test_cluster_performance.py::test_cluster_performance | Check that a cluster environment did not exceed certain thresholds. | 4.37 | ||||||||||||||||||||||||||||
artifacts_path = '/mnt/efs/tmp/CLUSTER-Workload_benchmarks_metrics/B_504' n_workers = 25, n_agents = 50000 def test_cluster_performance(artifacts_path, n_workers, n_agents): """Check that a cluster environment did not exceed certain thresholds. This test obtains various statistics (mean, max, regression coefficient) from CSVs with data generated in a cluster environment (resources used and duration of tasks). These statistics are compared with thresholds established in the data folder. Args: artifacts_path (str): Path where CSVs with cluster information can be found. n_workers (int): Number of workers folders that are expected inside the artifacts path. n_agents (int): Number of agents in the cluster environment. """ if None in (artifacts_path, n_workers, n_agents): pytest.fail("Parameters '--artifacts_path=<path> --n_workers=<n_workers> --n_agents=<n_agents>' are required.") # Check if there are threshold data for the specified number of workers and agents. selected_conf = f"{n_workers}w_{n_agents}a" if selected_conf not in configurations: pytest.fail(f"This is not a supported configuration: {selected_conf}. " f"Supported configurations are: {', '.join(configurations.keys())}.") # Check if path exists and if expected number of workers matches what is found inside artifacts. try: cluster_info = ClusterEnvInfo(artifacts_path).get_all_info() except FileNotFoundError: pytest.fail(f"Path '{artifacts_path}' could not be found or it may not follow the proper structure.") if cluster_info.get('worker_nodes', 0) != int(n_workers): pytest.fail(f"Information of {n_workers} workers was expected inside the artifacts folder, but " f"{cluster_info.get('worker_nodes', 0)} were found.") # Calculate stats from data inside artifacts path. data = {'tasks': ClusterCSVTasksParser(artifacts_path).get_stats(), 'resources': ClusterCSVResourcesParser(artifacts_path).get_stats()} if not data['tasks'] or not data['resources']: pytest.fail(f"Stats could not be retrieved, '{artifacts_path}' path may not exist, it is empty or it may not" f" follow the proper structure.") # Compare each stat with its threshold. for data_name, data_stats in data.items(): for phase, files in data_stats.items(): for file, columns in files.items(): for column, nodes in columns.items(): for node_type, stats in nodes.items(): for stat, value in stats.items(): th_value = configurations[selected_conf][data_name][phase][file][column][node_type][stat] if value[1] >= th_value: exceeded_thresholds.append({'value': value[1], 'threshold': th_value, 'stat': stat, 'column': column, 'node': value[0], 'file': file, 'phase': phase}) try: > assert not exceeded_thresholds, 'Some thresholds were exceeded:\n- ' + '\n- '.join( '{stat} {column} {value} >= {threshold} ({node}, {file}, {phase})'.format(**item) for item in exceeded_thresholds) E AssertionError: Some thresholds were exceeded: E - max time_spent(s) 16.517 >= 8.5 (worker_21, agent-info_sync, stable_phase) E - mean time_spent(s) 1.4408102564102565 >= 1 (master, agent-info_sync, stable_phase) E - max time_spent(s) 15.957 >= 5 (master, agent-info_sync, stable_phase) E assert not [{'column': 'time_spent(s)', 'file': 'agent-info_sync', 'node': 'worker_21', 'phase': 'stable_phase', ...}, {'column':...e_phase', ...}, {'column': 'time_spent(s)', 'file': 'agent-info_sync', 'node': 'master', 'phase': 'stable_phase', ...}] wazuh-qa/tests/performance/test_cluster/test_cluster_performance/test_cluster_performance.py:85: AssertionError ------------------------------Captured stdout call------------------------------ Setup phase took 0:20:46s (2024/05/03 19:15:10 - 2024/05/03 19:35:56). Stable phase took 0:04:01s (2024/05/03 19:35:56 - 2024/05/03 19:39:57). |