Commit ef5b7fa4 authored by Tien-Thinh Nguyen's avatar Tien-Thinh Nguyen

Itti message to trigger Slice Selection Subscription Data Retrieval

parent eaac1b10
...@@ -3711,14 +3711,13 @@ bool amf_n1::reroute_registration_request(std::shared_ptr<nas_context>& nc) { ...@@ -3711,14 +3711,13 @@ bool amf_n1::reroute_registration_request(std::shared_ptr<nas_context>& nc) {
// UDM // UDM
return false; return false;
} }
if (check_requested_nssai( // Check that AMF can process the Requested NSSAIs or not
nc, if (check_requested_nssai(nc, nssai)) {
nssai)) { // Check that AMF can process the Requested NSSAIs or not
return false; return false;
} }
// Process NS selection to select the appropriate AMF // Process NS selection to select the appropriate AMF
std::string nf_instance_id = {}; std::string nf_instance_id = {};
slice_info_fo_registration_t slice_info = {}; slice_info_for_registration_t slice_info = {};
authorized_network_slice_info_t authorized_network_slice_info = {}; authorized_network_slice_info_t authorized_network_slice_info = {};
if (!get_network_slice_selection( if (!get_network_slice_selection(
nf_instance_id, slice_info, authorized_network_slice_info)) { nf_instance_id, slice_info, authorized_network_slice_info)) {
...@@ -3744,13 +3743,16 @@ bool amf_n1::get_slice_selection_subscription_data( ...@@ -3744,13 +3743,16 @@ bool amf_n1::get_slice_selection_subscription_data(
const std::shared_ptr<nas_context>& nc, nssai_t& nssai) const { const std::shared_ptr<nas_context>& nc, nssai_t& nssai) const {
// TODO: UDM selection (from NRF or configuration file) // TODO: UDM selection (from NRF or configuration file)
if (amf_cfg.support_features.enable_external_udm) { if (amf_cfg.support_features.enable_external_udm) {
} else {
// TODO: get from the conf file
} }
return true; return true;
} }
//------------------------------------------------------------------------------ //------------------------------------------------------------------------------
bool amf_n1::get_network_slice_selection( bool amf_n1::get_network_slice_selection(
const std::string& nf_instance_id, slice_info_fo_registration_t& slice_info, const std::string& nf_instance_id,
slice_info_for_registration_t& slice_info,
authorized_network_slice_info_t& authorized_network_slice_info) const { authorized_network_slice_info_t& authorized_network_slice_info) const {
// TODO: UDM selection (from NRF or configuration file) // TODO: UDM selection (from NRF or configuration file)
if (amf_cfg.support_features.enable_external_udm) { if (amf_cfg.support_features.enable_external_udm) {
...@@ -3758,6 +3760,7 @@ bool amf_n1::get_network_slice_selection( ...@@ -3758,6 +3760,7 @@ bool amf_n1::get_network_slice_selection(
return true; return true;
} }
//------------------------------------------------------------------------------
void amf_n1::send_n1_message_notity( void amf_n1::send_n1_message_notity(
const std::shared_ptr<nas_context>& nc, const std::shared_ptr<nas_context>& nc,
const std::string& target_amf) const {} const std::string& target_amf) const {}
...@@ -71,7 +71,6 @@ using namespace std; ...@@ -71,7 +71,6 @@ using namespace std;
extern itti_mw* itti_inst; extern itti_mw* itti_inst;
extern amf_n2* amf_n2_inst; extern amf_n2* amf_n2_inst;
extern amf_n1* amf_n1_inst; extern amf_n1* amf_n1_inst;
extern amf_n11* amf_n11_inst;
extern amf_config amf_cfg; extern amf_config amf_cfg;
extern amf_app* amf_app_inst; extern amf_app* amf_app_inst;
extern statistics stacs; extern statistics stacs;
......
...@@ -61,7 +61,7 @@ typedef struct mapping_of_snssai_s { ...@@ -61,7 +61,7 @@ typedef struct mapping_of_snssai_s {
snssai_t home_snssai; snssai_t home_snssai;
} mapping_of_snssai_t; } mapping_of_snssai_t;
typedef struct slice_info_fo_registration_s { typedef struct slice_info_for_registration_s {
std::vector<subscribed_snssai_t> subscribed_nssai; std::vector<subscribed_snssai_t> subscribed_nssai;
std::vector<allowed_nssai_t> allowed_nssai_current_access; std::vector<allowed_nssai_t> allowed_nssai_current_access;
// allowed_nssai_other_access // allowed_nssai_other_access
...@@ -70,7 +70,7 @@ typedef struct slice_info_fo_registration_s { ...@@ -70,7 +70,7 @@ typedef struct slice_info_fo_registration_s {
bool default_configured_snssai_ind; bool default_configured_snssai_ind;
std::vector<mapping_of_snssai_t> mapping_of_nssai; std::vector<mapping_of_snssai_t> mapping_of_nssai;
bool request_mapping; bool request_mapping;
} slice_info_fo_registration_t; } slice_info_for_registration_t;
typedef struct configured_snssai_s { typedef struct configured_snssai_s {
snssai_t configured_snssai; snssai_t configured_snssai;
......
...@@ -86,6 +86,7 @@ typedef enum { ...@@ -86,6 +86,7 @@ typedef enum {
N11_UPDATE_NF_INSTANCE_REQUEST, N11_UPDATE_NF_INSTANCE_REQUEST,
N11_UPDATE_NF_INSTANCE_RESPONSE, N11_UPDATE_NF_INSTANCE_RESPONSE,
N11_DEREGISTER_NF_INSTANCE, N11_DEREGISTER_NF_INSTANCE,
N11_SLICE_SELECTION_SUBSCRIPTION_DATA,
SBI_EVENT_EXPOSURE_REQUEST, SBI_EVENT_EXPOSURE_REQUEST,
SBI_NOTIFICATION_DATA, SBI_NOTIFICATION_DATA,
SBI_NOTIFY_SUBSCRIBED_EVENT, SBI_NOTIFY_SUBSCRIBED_EVENT,
......
...@@ -191,4 +191,20 @@ class itti_n11_deregister_nf_instance : public itti_msg_n11 { ...@@ -191,4 +191,20 @@ class itti_n11_deregister_nf_instance : public itti_msg_n11 {
std::string amf_instance_id; std::string amf_instance_id;
}; };
//-----------------------------------------------------------------------------
class itti_n11_slice_selection_subscription_data : public itti_msg_n11 {
public:
itti_n11_slice_selection_subscription_data(
const task_id_t orig, const task_id_t dest)
: itti_msg_n11(N11_SLICE_SELECTION_SUBSCRIPTION_DATA, orig, dest),
http_version(1) {}
const char* get_msg_name() {
return "N11_SLICE_SELECTION_SUBSCRIPTION_DATA";
};
uint8_t http_version;
std::string supi;
plmn_t plmn;
};
#endif #endif
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