diff --git a/.gitlab/ci/e2e.yml b/.gitlab/ci/e2e.yml index 18b1c16482..878589753c 100644 --- a/.gitlab/ci/e2e.yml +++ b/.gitlab/ci/e2e.yml @@ -74,6 +74,7 @@ custom e2e: when: never - if: $ON_WEB - if: $ON_API + timeout: 28 hours needs: - *retina-needs - custom build @@ -494,6 +495,7 @@ viavi-extended: - if: $CI_DESCRIPTION =~ /Weekly/ variables: KEYWORDS: "extended and not 24h" + timeout: 28 hours needs: - job: "basic avx512 dpdk" artifacts: true diff --git a/.gitlab/run_viavi_pipeline.py b/.gitlab/run_viavi_pipeline.py index 2188795700..4d257b59ef 100755 --- a/.gitlab/run_viavi_pipeline.py +++ b/.gitlab/run_viavi_pipeline.py @@ -20,21 +20,22 @@ DEFAULT_BUILD_ARGS = '-DCMAKE_BUILD_TYPE=Release -DFORCE_DEBUG_INFO=True -DENABLE_UHD=False -DENABLE_DPDK=True -DENABLE_ZEROMQ=False -DMARCH="x86-64-v4"' DEFAULT_DPDK_VERSION = "23.11.1_avx512" + # pylint: disable=too-many-instance-attributes @dataclass class _TestDefinition: - """ - """ + """ """ - campaign_filename: str = "" id: str = "" + campaign_filename: str = "" + test_name: str = "" description: str = "" + # pylint: disable=too-many-instance-attributes @dataclass class _ArgsDefinition: - """ - """ + """ """ testlist: bool = False token: str = "" @@ -46,20 +47,25 @@ class _ArgsDefinition: build_args: str = DEFAULT_BUILD_ARGS dpdk_version: str = DEFAULT_DPDK_VERSION + def get_viavi_tests(): - viavi_test_declaration = (pathlib.Path(__file__).parent / '..' / 'tests' / 'e2e' / 'tests' / 'viavi' / 'test_declaration.yml').resolve() - with open(viavi_test_declaration, 'r') as file: + viavi_test_declaration = ( + pathlib.Path(__file__).parent / ".." / "tests" / "e2e" / "tests" / "viavi" / "test_declaration.yml" + ).resolve() + with open(viavi_test_declaration, "r", encoding="utf-8") as file: data = yaml.safe_load(file) - test_list : List[_TestDefinition] = [] - for test in data['tests']: + test_list: List[_TestDefinition] = [] + for test in data["tests"]: test_definition = _TestDefinition() - test_definition.campaign_filename = test['campaign_filename'] - test_definition.id = test['id'] - test_definition.description = test.get('description', '') + test_definition.id = test["id"] + test_definition.campaign_filename = test["campaign_filename"] + test_definition.test_name = test["test_name"] + test_definition.description = test.get("description", "") test_list.append(test_definition) return test_list + def validate_args(args) -> _ArgsDefinition: args_definition = _ArgsDefinition() args_definition.testlist = args.testlist @@ -87,6 +93,7 @@ def validate_args(args) -> _ArgsDefinition: exit(1) return args_definition + def show_test_list(): test_list = get_viavi_tests() print("Available tests:") @@ -114,7 +121,7 @@ def run_test(args_definition: _ArgsDefinition, test_definition: _TestDefinition) TESTBED = "viavi" MARKERS = "viavi_manual" - PYARGS = f'--viavi-manual-campaign-filename "{test_definition.campaign_filename}" --viavi-manual-test-name "{test_definition.id}" --viavi-manual-test-timeout {timeout} --retina-pod-timeout 900' + PYARGS = f'--viavi-manual-campaign-filename "{test_definition.campaign_filename}" --viavi-manual-test-name "{test_definition.test_name}" --viavi-manual-test-timeout {timeout} --retina-pod-timeout 900' if args_definition.gnb_extra: PYARGS += f' --viavi-manual-extra-gnb-arguments "{args_definition.gnb_extra}"' @@ -153,6 +160,8 @@ def run_test(args_definition: _ArgsDefinition, test_definition: _TestDefinition) pipeline_url = pipeline.web_url print(f"Pipeline created: {pipeline_url}") + + def main(): """ Entrypoint runner. @@ -173,7 +182,7 @@ def main(): parser.add_argument( "--testid", - help='[REQUIRED] Testid in the campaign.', + help="[REQUIRED] Testid in the campaign.", ) parser.add_argument( @@ -194,9 +203,7 @@ def main(): default=DEFAULT_DPDK_VERSION, ) - parser.add_argument( - "--timeout", help="Timeout in seconds for the test" - ) + parser.add_argument("--timeout", help="Timeout in seconds for the test") args_definition = validate_args(parser.parse_args()) if args_definition.testlist: @@ -211,5 +218,6 @@ def main(): print(f"Testid {args_definition.testid} not found.") exit(1) + if __name__ == "__main__": main() diff --git a/apps/units/flexible_o_du/split_helpers/o_du_high_factory.cpp b/apps/units/flexible_o_du/split_helpers/o_du_high_factory.cpp index 66e7fce073..e56c625f8c 100644 --- a/apps/units/flexible_o_du/split_helpers/o_du_high_factory.cpp +++ b/apps/units/flexible_o_du/split_helpers/o_du_high_factory.cpp @@ -76,6 +76,7 @@ std::vector srsran::make_multicell_with_multi_du(const o_du_high tmp_cfg.du_high_cfg.config.cells_cfg.resize(1); tmp_cfg.du_high_cfg.config.cells_cfg[0] = du_hi.cells_cfg[i]; tmp_cfg.fapi_cfg = o_du_high_unit_cfg.fapi_cfg; + tmp_cfg.e2_cfg = o_du_high_unit_cfg.e2_cfg; srs_du::o_du_high_dependencies sector_deps; sector_deps.sectors.push_back(dependencies.o_du_hi_dependencies.sectors[i]); diff --git a/lib/e2/common/e2_entity.cpp b/lib/e2/common/e2_entity.cpp index afd4277206..9157f5ff2c 100644 --- a/lib/e2/common/e2_entity.cpp +++ b/lib/e2/common/e2_entity.cpp @@ -39,7 +39,7 @@ using namespace srsran; using namespace asn1::e2ap; using metrics_interface = std::variant; -e2_entity::e2_entity(const e2ap_configuration& cfg_, +e2_entity::e2_entity(const e2ap_configuration cfg_, e2_connection_client& e2_client_, metrics_interface e2_metrics_, srs_du::f1ap_ue_id_translator* f1ap_ue_id_translator_, @@ -76,7 +76,7 @@ e2_entity::e2_entity(const e2ap_configuration& cfg_, e2sm_mngr->add_e2sm_service(e2sm_rc_asn1_packer::oid, std::move(e2sm_rc_iface)); } - e2ap = std::make_unique(cfg_, *this, timers_, e2_client_, *subscription_mngr, *e2sm_mngr, task_exec_); + e2ap = std::make_unique(cfg, *this, timers_, e2_client_, *subscription_mngr, *e2sm_mngr, task_exec_); } void e2_entity::build_e2_kpm_du(metrics_interface e2_metrics_, srs_du::f1ap_ue_id_translator* f1ap_ue_id_translator) diff --git a/lib/e2/common/e2_entity.h b/lib/e2/common/e2_entity.h index 1faf7489e1..e82ff8a4c1 100644 --- a/lib/e2/common/e2_entity.h +++ b/lib/e2/common/e2_entity.h @@ -46,7 +46,7 @@ namespace srsran { class e2_entity final : public e2_agent { public: - e2_entity(const e2ap_configuration& cfg_, + e2_entity(const e2ap_configuration cfg_, e2_connection_client& e2_client_, std::variant e2_metrics_, srs_du::f1ap_ue_id_translator* f1ap_ue_id_translator_, @@ -62,8 +62,8 @@ class e2_entity final : public e2_agent void on_e2_disconnection() override; private: - srslog::basic_logger& logger; - const e2ap_configuration& cfg; + srslog::basic_logger& logger; + const e2ap_configuration cfg; void build_e2_kpm_du(std::variant e2_metrics_, srs_du::f1ap_ue_id_translator* f1ap_ue_id_translator); diff --git a/lib/e2/e2sm/e2sm_kpm/e2sm_kpm_du_meas_provider_impl.cpp b/lib/e2/e2sm/e2sm_kpm/e2sm_kpm_du_meas_provider_impl.cpp index c6fd4172a5..6070819622 100644 --- a/lib/e2/e2sm/e2sm_kpm/e2sm_kpm_du_meas_provider_impl.cpp +++ b/lib/e2/e2sm/e2sm_kpm/e2sm_kpm_du_meas_provider_impl.cpp @@ -106,9 +106,9 @@ e2sm_kpm_du_meas_provider_impl::e2sm_kpm_du_meas_provider_impl(srs_du::f1ap_ue_i e2sm_kpm_supported_metric_t{ NO_LABEL, ALL_LEVELS, true, &e2sm_kpm_du_meas_provider_impl::get_drb_ul_rlc_sdu_latency}); - supported_metrics.emplace( - "RACH.PreambleDedCell", - e2sm_kpm_supported_metric_t{NO_LABEL, ALL_LEVELS, true, &e2sm_kpm_du_meas_provider_impl::get_prach_cell_count}); + supported_metrics.emplace("RACH.PreambleDedCell", + e2sm_kpm_supported_metric_t{ + NO_LABEL, E2_NODE_LEVEL, true, &e2sm_kpm_du_meas_provider_impl::get_prach_cell_count}); // Check if the supported metrics are matching e2sm_kpm metrics definitions. check_e2sm_kpm_metrics_definitions(get_e2sm_kpm_28_552_metrics()); diff --git a/lib/ofh/receiver/ofh_closed_rx_window_handler.cpp b/lib/ofh/receiver/ofh_closed_rx_window_handler.cpp index 6b6fa8f812..234260639c 100644 --- a/lib/ofh/receiver/ofh_closed_rx_window_handler.cpp +++ b/lib/ofh/receiver/ofh_closed_rx_window_handler.cpp @@ -101,7 +101,7 @@ void closed_rx_window_handler::handle_prach_context(slot_symbol_point symbol_poi if (log_unreceived_messages) { logger.warning("Missed incoming User-Plane PRACH messages for slot '{}' and sector#{}", - ctx_value.context.sector, + ctx_value.context.slot, ctx_value.context.sector); } diff --git a/tests/benchmarks/pdcp/CMakeLists.txt b/tests/benchmarks/pdcp/CMakeLists.txt index 506845dbf6..0ab3f88339 100644 --- a/tests/benchmarks/pdcp/CMakeLists.txt +++ b/tests/benchmarks/pdcp/CMakeLists.txt @@ -24,10 +24,22 @@ include_directories(../../..) add_executable(pdcp_tx_benchmark pdcp_tx_benchmark.cpp) target_link_libraries(pdcp_tx_benchmark srsran_pdcp srsran_security srslog) -add_test(pdcp_tx_benchmark pdcp_tx_benchmark) -set_tests_properties(pdcp_tx_benchmark PROPERTIES LABELS "tsan") +add_test(pdcp_tx_benchmark_nea0 pdcp_tx_benchmark -a0 -R3) +add_test(pdcp_tx_benchmark_nea1 pdcp_tx_benchmark -a1 -R1) +add_test(pdcp_tx_benchmark_nea2 pdcp_tx_benchmark -a2 -R3) +add_test(pdcp_tx_benchmark_nea3 pdcp_tx_benchmark -a3 -R1) +set_tests_properties(pdcp_tx_benchmark_nea0 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_tx_benchmark_nea1 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_tx_benchmark_nea2 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_tx_benchmark_nea3 PROPERTIES LABELS "tsan") add_executable(pdcp_rx_benchmark pdcp_rx_benchmark.cpp) target_link_libraries(pdcp_rx_benchmark srsran_pdcp srsran_security srslog) -add_test(pdcp_rx_benchmark pdcp_rx_benchmark) -set_tests_properties(pdcp_rx_benchmark PROPERTIES LABELS "tsan") +add_test(pdcp_rx_benchmark_nea0 pdcp_rx_benchmark -a0 -R3) +add_test(pdcp_rx_benchmark_nea1 pdcp_rx_benchmark -a1 -R1) +add_test(pdcp_rx_benchmark_nea2 pdcp_rx_benchmark -a2 -R3) +add_test(pdcp_rx_benchmark_nea3 pdcp_rx_benchmark -a3 -R1) +set_tests_properties(pdcp_rx_benchmark_nea0 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_rx_benchmark_nea1 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_rx_benchmark_nea2 PROPERTIES LABELS "tsan") +set_tests_properties(pdcp_rx_benchmark_nea3 PROPERTIES LABELS "tsan") diff --git a/tests/benchmarks/pdcp/pdcp_rx_benchmark.cpp b/tests/benchmarks/pdcp/pdcp_rx_benchmark.cpp index 600e8b56f3..7c9296d037 100644 --- a/tests/benchmarks/pdcp/pdcp_rx_benchmark.cpp +++ b/tests/benchmarks/pdcp/pdcp_rx_benchmark.cpp @@ -79,7 +79,7 @@ class pdcp_rx_test_frame : public pdcp_tx_status_handler, }; struct bench_params { - unsigned nof_repetitions = 8; + unsigned nof_repetitions = 10; unsigned nof_crypto_threads = 8; unsigned crypto_queue_size = 4096; bool print_timing_info = false; diff --git a/tests/benchmarks/pdcp/pdcp_tx_benchmark.cpp b/tests/benchmarks/pdcp/pdcp_tx_benchmark.cpp index 05d9392d83..f72e50c144 100644 --- a/tests/benchmarks/pdcp/pdcp_tx_benchmark.cpp +++ b/tests/benchmarks/pdcp/pdcp_tx_benchmark.cpp @@ -51,7 +51,7 @@ class pdcp_tx_gen_frame : public pdcp_tx_lower_notifier, public pdcp_tx_upper_co }; struct bench_params { - unsigned nof_repetitions = 8; + unsigned nof_repetitions = 10; bool print_timing_info = false; unsigned nof_sdus = 1024; unsigned sdu_len = 1500; diff --git a/tests/e2e/tests/viavi.py b/tests/e2e/tests/viavi.py index 32bb653f52..b7850eae3f 100644 --- a/tests/e2e/tests/viavi.py +++ b/tests/e2e/tests/viavi.py @@ -651,6 +651,7 @@ def get_viavi_configuration_from_testname( """ Get Viavi configuration from dict """ + test_declaration = None config = load_yaml_config("test_declaration.yml") for test_config in config: if test_config.test_name == test_name: diff --git a/tests/e2e/tests/viavi/test_declaration.yml b/tests/e2e/tests/viavi/test_declaration.yml index 030f95b31f..870254d3a7 100644 --- a/tests/e2e/tests/viavi/test_declaration.yml +++ b/tests/e2e/tests/viavi/test_declaration.yml @@ -33,7 +33,7 @@ campaign_filename: &campaign_filename "C:\\ci\\CI 4x4 ORAN-FH-complete.xml" gnb_extra_commands: &gnb_extra_commands "log --metrics_level=info metrics --rlc_report_period=1000" -gnb_extra_commands_no_warn: &gnb_extra_commands_no_warn "log --all_level=error metrics --stdout_metrics_period=5000 --rlc_report_period=5000" +gnb_extra_commands_no_warn: &gnb_extra_commands_no_warn "log --all_level=error metrics --sched_report_period=5000 --rlc_report_period=5000" test_timeout: &test_timeout 2400