X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=E2Manager%2Fhandlers%2Frmrmsghandlers%2Fe2_setup_request_notification_handler.go;h=3e58c31b4a70cb86e9c2afe61c645de255e13f31;hb=3e56457a6f08b1d3b89836ed7782cf3744a29ba6;hp=9ea0ef5929fe1205b3a6afd78cefa5211f40d044;hpb=0823945d1b5a326844833187a36bea669752be93;p=ric-plt%2Fe2mgr.git diff --git a/E2Manager/handlers/rmrmsghandlers/e2_setup_request_notification_handler.go b/E2Manager/handlers/rmrmsghandlers/e2_setup_request_notification_handler.go index 9ea0ef5..3e58c31 100644 --- a/E2Manager/handlers/rmrmsghandlers/e2_setup_request_notification_handler.go +++ b/E2Manager/handlers/rmrmsghandlers/e2_setup_request_notification_handler.go @@ -236,6 +236,14 @@ func (h E2SetupRequestNotificationHandler) parseSetupRequest(payload []byte) (*m return nil, "", errors.New(fmt.Sprintf("#E2SetupRequestNotificationHandler.parseSetupRequest - Error unmarshalling E2 Setup Request payload: %x", payload)) } + ranFunctionsList := setupRequest.E2APPDU.InitiatingMessage.Value.E2setupRequest.ProtocolIEs.E2setupRequestIEs[1].Value.RANfunctionsList.ProtocolIESingleContainer + + for i := 0; i < len(ranFunctionsList); i++ { + def := models.E2smGnbNrtRanFunctionDefinition{} + err = xml.Unmarshal([]byte(ranFunctionsList[i].Value.RANfunctionItem.RanFunctionDefinition.Text), &def) + ranFunctionsList[i].Value.RANfunctionItem.RanFunctionDefinition.E2smGnbNrtRanFunctionDefinition = def + } + return setupRequest, e2tIpAddress, nil } @@ -248,7 +256,7 @@ func (h E2SetupRequestNotificationHandler) buildNodebInfo(ranName string, e2tAdd RanName: ranName, NodeType: entities.Node_GNB, Configuration: &entities.NodebInfo_Gnb{Gnb: &entities.Gnb{}}, - GlobalNbId: h.buildGlobalNbId(request), + GlobalNbId: h.buildGlobalNbId(request), } err = h.setGnbFunctions(nodebInfo, request) @@ -265,6 +273,6 @@ func (h E2SetupRequestNotificationHandler) buildGlobalNbId(setupRequest *models. func (h E2SetupRequestNotificationHandler) buildNbIdentity(ranName string, setupRequest *models.E2SetupRequestMessage) *entities.NbIdentity { return &entities.NbIdentity{ InventoryName: ranName, - GlobalNbId: h.buildGlobalNbId(setupRequest), + GlobalNbId: h.buildGlobalNbId(setupRequest), } }