Merge remote-tracking branch 'origin/ci-oai-flexric' into integration_2026_w22 (!4098)

[CI OAI-FlexRIC] Improve CI pipeline

1. Run the iperf instead of ping
2. SIGTERM added for nearRT-RIC so it shall gracefully stop in CI;
   modify the line for nearRT-RIC service analysis

Reviewed-by: Jaroslava Fiedlerova <jaroslava.fiedlerova@openairinterface.org>
This commit is contained in:
Robert Schmidt
2026-05-28 19:00:41 +02:00
5 changed files with 39 additions and 23 deletions

View File

@@ -70,7 +70,7 @@
<class>Attach_UE</class>
<desc>Attach OAI UE 1 and 2</desc>
<id>rfsim5g_ue rfsim5g_ue2</id>
<node>carabe</node>
<node>localhost</node>
</testCase>
<testCase>
@@ -98,21 +98,32 @@
</testCase>
<testCase>
<class>Ping</class>
<desc>Ping ext-dn from both UEs</desc>
<class>Iperf</class>
<desc>Iperf (DL/TCP)(20 sec)</desc>
<iperf_args>-t 20 -R</iperf_args>
<id>rfsim5g_ue rfsim5g_ue2</id>
<node>carabe</node>
<node>localhost</node>
<svr_id>oai_ext_dn</svr_id>
<svr_node>carabe</svr_node>
<ping_args>-c 20</ping_args>
<ping_packetloss_threshold>5</ping_packetloss_threshold>
<svr_node>localhost</svr_node>
<iperf_tcp_rate_target>10</iperf_tcp_rate_target>
</testCase>
<testCase>
<class>Iperf</class>
<desc>Iperf (UL/TCP)(20 sec)</desc>
<iperf_args>-t 20</iperf_args>
<id>rfsim5g_ue rfsim5g_ue2</id>
<node>localhost</node>
<svr_id>oai_ext_dn</svr_id>
<svr_node>localhost</svr_node>
<iperf_tcp_rate_target>5</iperf_tcp_rate_target>
</testCase>
<testCase>
<class>Detach_UE</class>
<desc>Detach OAI UE 1 and 2</desc>
<id>rfsim5g_ue rfsim5g_ue2</id>
<node>carabe</node>
<node>localhost</node>
</testCase>
<testCase>
@@ -178,7 +189,7 @@
<yaml_path>ci-scripts/yaml_files/5g_rfsimulator_flexric</yaml_path>
<always_exec>true</always_exec>
<analysis>
<service>nearRT-RIC=LastLineContains=Removing E2 Node</service>
<service>nearRT-RIC=LastLineContains=The nearRT-RIC run SUCCESSFULLY</service>
<service>xapp-rc-moni=LastLineContains=Test xApp run SUCCESSFULLY</service>
<service>xapp-kpm-moni=LastLineContains=Test xApp run SUCCESSFULLY</service>
<service>xapp-kpm-rc=LastLineContains=Test xApp run SUCCESSFULLY</service>

View File

@@ -31,6 +31,8 @@ bool read_mac_sm(void* data)
assert(mac->msg.ue_stats != NULL && "Memory exhausted" );
}
gNB_MAC_INST *mac_inst = RC.nrmac[0];
NR_SCHED_LOCK(&mac_inst->sched_lock);
size_t i = 0; //TODO
UE_iterator(UE_info->connected_ue_list, UE) {
const NR_UE_sched_ctrl_t* sched_ctrl = &UE->UE_sched_ctrl;
@@ -93,6 +95,7 @@ bool read_mac_sm(void* data)
++i;
}
NR_SCHED_UNLOCK(&mac_inst->sched_lock);
return num_ues > 0;
}

View File

@@ -12,9 +12,6 @@
#include "openair2/LAYER2/nr_rlc/nr_rlc_oai_api.h"
#include "openair2/E2AP/flexric/src/util/time_now_us.h"
static
const int mod_id = 0;
static
uint32_t num_act_rb(NR_UEs_t* const UE_info)
{
@@ -57,20 +54,22 @@ bool read_rlc_sm(void* data)
rlc_ind_data_t* rlc = (rlc_ind_data_t*)data;
//fill_rlc_ind_data(rlc);
// use MAC structures to get RNTIs
NR_UEs_t *UE_info = &RC.nrmac[mod_id]->UE_info;
gNB_MAC_INST *mac_inst = RC.nrmac[0];
NR_SCHED_LOCK(&mac_inst->sched_lock);
NR_UEs_t *UE_info = &mac_inst->UE_info;
uint32_t const act_rb = num_act_rb(UE_info);
//assert(0!=0 && "Read RLC called");
rlc->msg.len = act_rb;
if (act_rb == 0) {
NR_SCHED_UNLOCK(&mac_inst->sched_lock);
return false;
}
rlc->msg.rb = calloc(rlc->msg.len, sizeof(rlc_radio_bearer_stats_t));
assert(rlc->msg.rb != NULL && "Memory exhausted");
// activate the rlc to calculate the average tx time
active_avg_to_tx(UE_info);
rlc->msg.len = act_rb;
if(rlc->msg.len > 0){
rlc->msg.rb = calloc(rlc->msg.len, sizeof(rlc_radio_bearer_stats_t));
assert(rlc->msg.rb != NULL && "Memory exhausted");
}
rlc->msg.tstamp = time_now_us();
uint32_t i = 0;
@@ -143,6 +142,7 @@ bool read_rlc_sm(void* data)
++i;
}
}
NR_SCHED_UNLOCK(&mac_inst->sched_lock);
return act_rb > 0;
}

View File

@@ -185,7 +185,8 @@ static meas_record_lst_t fill_RRU_PrbTotDl(__attribute__((unused)) const label_i
meas_record.value = INTEGER_MEAS_VALUE;
// Get the number of DL PRBs
meas_record.int_val = (ue_info.ue->mac_stats.dl.total_rbs - last_total_prbs[ue_idx].dl) * 100 / (node_stats[1].mac_stats.dl.total_prb_aggregate - node_stats[0].mac_stats.dl.total_prb_aggregate); // [%]
const uint64_t tot_prb_dl_aggr = node_stats[1].mac_stats.dl.total_prb_aggregate - node_stats[0].mac_stats.dl.total_prb_aggregate;
meas_record.int_val = (tot_prb_dl_aggr == 0) ? 0 : (ue_info.ue->mac_stats.dl.total_rbs - last_total_prbs[ue_idx].dl) * 100 / tot_prb_dl_aggr; // [%]
last_total_prbs[ue_idx].dl = ue_info.ue->mac_stats.dl.total_rbs;
return meas_record;
@@ -204,7 +205,8 @@ static meas_record_lst_t fill_RRU_PrbTotUl(__attribute__((unused)) const label_i
meas_record.value = INTEGER_MEAS_VALUE;
// Get the number of UL PRBs
meas_record.int_val = (ue_info.ue->mac_stats.ul.total_rbs - last_total_prbs[ue_idx].ul) * 100 / (node_stats[1].mac_stats.ul.total_prb_aggregate - node_stats[0].mac_stats.ul.total_prb_aggregate); // [%]
const uint64_t tot_prb_ul_aggr = node_stats[1].mac_stats.ul.total_prb_aggregate - node_stats[0].mac_stats.ul.total_prb_aggregate;
meas_record.int_val = (tot_prb_ul_aggr == 0) ? 0 : (ue_info.ue->mac_stats.ul.total_rbs - last_total_prbs[ue_idx].ul) * 100 / tot_prb_ul_aggr; // [%]
last_total_prbs[ue_idx].ul = ue_info.ue->mac_stats.ul.total_rbs;
return meas_record;