Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-SMF
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenXG
OpenXG-SMF
Commits
75cf50e2
Commit
75cf50e2
authored
Feb 22, 2021
by
Tien-Thinh Nguyen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update the UPF node selection for Network Triggered Service Request
parent
b8865508
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
19 additions
and
13 deletions
+19
-13
src/smf_app/smf_app.cpp
src/smf_app/smf_app.cpp
+9
-4
src/smf_app/smf_context.cpp
src/smf_app/smf_context.cpp
+1
-7
src/smf_app/smf_pfcp_association.cpp
src/smf_app/smf_pfcp_association.cpp
+9
-2
No files found.
src/smf_app/smf_app.cpp
View file @
75cf50e2
...
...
@@ -543,10 +543,15 @@ void smf_app::handle_itti_msg(
Logger
::
smf_app
().
debug
(
"Send failure indication to UPF"
);
// TODO: to be completed
pfcp
::
node_id_t
up_node_id
=
{};
// TODO: Update select_up_node function
if
(
not
pfcp_associations
::
get_instance
().
select_up_node
(
up_node_id
,
NODE_SELECTION_CRITERIA_MIN_PFCP_SESSIONS
))
{
Logger
::
smf_app
().
info
(
"REMOTE_PEER_NOT_RESPONDING"
);
// Get UPF node
std
::
shared_ptr
<
smf_context_ref
>
scf
=
{};
if
(
smf_app_inst
->
is_scid_2_smf_context
(
m
.
scid
))
{
scf
=
scid_2_smf_context
(
m
.
scid
);
up_node_id
=
scf
.
get
()
->
upf_node_id
;
}
else
{
Logger
::
smf_app
().
warn
(
"SM Context associated with this id "
SCID_FMT
" does not exit!"
,
m
.
scid
);
return
;
}
...
...
src/smf_app/smf_context.cpp
View file @
75cf50e2
...
...
@@ -748,13 +748,7 @@ void smf_context::handle_itti_msg(
scid
);
return
;
}
/*
if (not pfcp_associations::get_instance().select_up_node(
up_node_id, NODE_SELECTION_CRITERIA_MIN_PFCP_SESSIONS)) {
Logger::smf_app().info("REMOTE_PEER_NOT_RESPONDING");
return;
}
*/
itti_n4_session_report_response
*
n4_ser
=
new
itti_n4_session_report_response
(
TASK_SMF_APP
,
TASK_SMF_N4
);
n4_ser
->
seid
=
req
->
seid
;
...
...
src/smf_app/smf_pfcp_association.cpp
View file @
75cf50e2
...
...
@@ -38,11 +38,13 @@ using namespace std;
extern
itti_mw
*
itti_inst
;
extern
smf_n4
*
smf_n4_inst
;
//------------------------------------------------------------------------------
void
pfcp_association
::
notify_add_session
(
const
pfcp
::
fseid_t
&
cp_fseid
)
{
std
::
unique_lock
<
std
::
mutex
>
l
(
m_sessions
);
sessions
.
insert
(
cp_fseid
);
}
//------------------------------------------------------------------------------
bool
pfcp_association
::
has_session
(
const
pfcp
::
fseid_t
&
cp_fseid
)
{
std
::
unique_lock
<
std
::
mutex
>
l
(
m_sessions
);
...
...
@@ -75,6 +77,7 @@ void pfcp_association::restore_n4_sessions() {
restore_proc
->
run
();
}
}
//------------------------------------------------------------------------------
bool
pfcp_associations
::
add_association
(
pfcp
::
node_id_t
&
node_id
,
pfcp
::
recovery_time_stamp_t
&
recovery_time_stamp
,
...
...
@@ -114,6 +117,7 @@ bool pfcp_associations::add_association(
}
return
true
;
}
//------------------------------------------------------------------------------
bool
pfcp_associations
::
add_association
(
pfcp
::
node_id_t
&
node_id
,
pfcp
::
recovery_time_stamp_t
&
recovery_time_stamp
,
...
...
@@ -173,6 +177,7 @@ bool pfcp_associations::get_association(
return
true
;
}
}
//------------------------------------------------------------------------------
bool
pfcp_associations
::
get_association
(
const
pfcp
::
fseid_t
&
cp_fseid
,
...
...
@@ -196,6 +201,7 @@ void pfcp_associations::restore_n4_sessions(const pfcp::node_id_t& node_id) {
sa
->
restore_n4_sessions
();
}
}
//------------------------------------------------------------------------------
void
pfcp_associations
::
trigger_heartbeat_request_procedure
(
std
::
shared_ptr
<
pfcp_association
>&
s
)
{
...
...
@@ -203,6 +209,7 @@ void pfcp_associations::trigger_heartbeat_request_procedure(
PFCP_ASSOCIATION_HEARTBEAT_INTERVAL_SEC
,
0
,
TASK_SMF_N4
,
TASK_SMF_N4_TRIGGER_HEARTBEAT_REQUEST
,
s
->
hash_node_id
);
}
//------------------------------------------------------------------------------
void
pfcp_associations
::
initiate_heartbeat_request
(
timer_id_t
timer_id
,
uint64_t
arg2_user
)
{
...
...
@@ -312,8 +319,7 @@ bool pfcp_associations::select_up_node(
}
// else, verify that UPF belongs to the same slice and supports this dnn
std
::
vector
<
snssai_t
>
snssais
=
{};
// a->upf_node_profile.get_nf_snssais(snssais);
upf_info_t
upf_info
=
{};
upf_info_t
upf_info
=
{};
a
->
upf_node_profile
.
get_upf_info
(
upf_info
);
for
(
auto
ui
:
upf_info
.
snssai_upf_info_list
)
{
if
(
ui
.
snssai
==
snssai
)
{
...
...
@@ -337,6 +343,7 @@ void pfcp_associations::notify_add_session(
sa
->
notify_add_session
(
cp_fseid
);
}
}
//------------------------------------------------------------------------------
void
pfcp_associations
::
notify_del_session
(
const
pfcp
::
fseid_t
&
cp_fseid
)
{
std
::
shared_ptr
<
pfcp_association
>
sa
=
{};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment