Commit ad2259d6 authored by Tien Thinh NGUYEN's avatar Tien Thinh NGUYEN

try to fix issue for recovery_time_stamp when testing with dsTester (UPF)

parent fd78292a
...@@ -215,7 +215,12 @@ smf_n4::smf_n4() ...@@ -215,7 +215,12 @@ smf_n4::smf_n4()
std::chrono::system_clock::now(); std::chrono::system_clock::now();
std::time_t now_c = std::chrono::system_clock::to_time_t(now); std::time_t now_c = std::chrono::system_clock::to_time_t(now);
std::time_t ellapsed = now_c - time_epoch; std::time_t ellapsed = now_c - time_epoch;
recovery_time_stamp = ellapsed; //recovery_time_stamp = ellapsed;
//test new way to calculate recovery_time_stamp
std::time_t time_epoch_ntp = std::time(nullptr);
uint64_t tv_ntp = time_epoch_ntp + SECONDS_SINCE_FIRST_EPOCH;
recovery_time_stamp = tv_ntp;
// TODO may load this from config // TODO may load this from config
cp_function_features = { }; cp_function_features = { };
...@@ -560,9 +565,12 @@ void smf_n4::send_n4_msg(itti_n4_session_report_response &i) { ...@@ -560,9 +565,12 @@ void smf_n4::send_n4_msg(itti_n4_session_report_response &i) {
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
void smf_n4::send_heartbeat_request(std::shared_ptr<pfcp_association> &a) { void smf_n4::send_heartbeat_request(std::shared_ptr<pfcp_association> &a) {
std::time_t time_epoch = std::time(nullptr);
uint64_t tv_ntp = time_epoch + SECONDS_SINCE_FIRST_EPOCH;
pfcp::pfcp_heartbeat_request h = { }; pfcp::pfcp_heartbeat_request h = { };
pfcp::recovery_time_stamp_t r = { .recovery_time_stamp = pfcp::recovery_time_stamp_t r = { .recovery_time_stamp =
(uint32_t) recovery_time_stamp }; (uint32_t) tv_ntp };
h.set(r); h.set(r);
pfcp::node_id_t &node_id = a->node_id; pfcp::node_id_t &node_id = a->node_id;
......
...@@ -1346,9 +1346,11 @@ void session_release_sm_context_procedure::handle_itti_msg( ...@@ -1346,9 +1346,11 @@ void session_release_sm_context_procedure::handle_itti_msg(
problem_details.setCause( problem_details.setCause(
pdu_session_application_error_e2str[PDU_SESSION_APPLICATION_ERROR_NETWORK_FAILURE]); pdu_session_application_error_e2str[PDU_SESSION_APPLICATION_ERROR_NETWORK_FAILURE]);
//trigger to send reply to AMF //trigger to send reply to AMF
/*
smf_app_inst->trigger_http_response( smf_app_inst->trigger_http_response(
http_status_code_e::HTTP_STATUS_CODE_406_NOT_ACCEPTABLE, http_status_code_e::HTTP_STATUS_CODE_406_NOT_ACCEPTABLE,
n11_triggered_pending->pid, N11_SESSION_RELEASE_SM_CONTEXT_RESPONSE); n11_triggered_pending->pid, N11_SESSION_RELEASE_SM_CONTEXT_RESPONSE);
*/
} }
//TODO: //TODO:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment