Commit 5c91a0e3 authored by Simon Pastor's avatar Simon Pastor
Browse files

exclusing it only on the nr notification

parent a7c802d8
Loading
Loading
Loading
Loading
+11 −8
Original line number Diff line number Diff line
@@ -1476,9 +1476,6 @@ func checkMrNotificationRegisteredSubscriptions(key string, jsonInfo string, ext
						}

						poaInfo := convertJsonToPoaInfo(jsonInfo)
						//4G and 5G neighbours information are mutually exclusive
						//If at least one 5G neighbor exist, only report 5G
						report5GNeighborOnly := false

						switch poaInfo.Type {
						case poaType4G:
@@ -1497,13 +1494,8 @@ func checkMrNotificationRegisteredSubscriptions(key string, jsonInfo string, ext
							measRepUeNotificationNrNCellInfo.NrNCellGId = poaInfo.Nrcgi.NrcellId
							neighborCell.NrNCellInfo = append(neighborCell.NrNCellInfo, measRepUeNotificationNrNCellInfo)
							notif.NewRadioMeasNeiInfo = append(notif.NewRadioMeasNeiInfo, neighborCell)
							report5GNeighborOnly = true
						default:
						}

						if report5GNeighborOnly {
							notif.EutranNeighbourCellMeasInfo = nil
						}
					}
				}

@@ -1601,6 +1593,10 @@ func checkNrMrNotificationRegisteredSubscriptions(key string, jsonInfo string, e

				notif.AssociateId = append(notif.AssociateId, *assocId)

				//4G and 5G neighbours information are mutually exclusive
				//If at least one 5G neighbor exist, only report 5G
				report5GNeighborOnly := false

				strongestRsrp := int32(0)
				//adding the data of all reachable cells
				for _, poa := range ueData.InRangePoas {
@@ -1637,6 +1633,8 @@ func checkNrMrNotificationRegisteredSubscriptions(key string, jsonInfo string, e
							}

							notif.NrNeighCellMeasInfo = append(notif.NrNeighCellMeasInfo, neighborCell)
							report5GNeighborOnly = true

						case poaType4G:
							var neighborCell NrMeasRepUeNotificationEutraNeighCellMeasInfo
							neighborCell.Rsrp = poa.Rsrp
@@ -1648,6 +1646,11 @@ func checkNrMrNotificationRegisteredSubscriptions(key string, jsonInfo string, e

					}
				}
				if report5GNeighborOnly {
					log.Info("SIMON4 ", report5GNeighborOnly)

					notif.EutraNeighCellMeasInfo = nil
				}

				go sendNrMrNotification(subscription.CallbackReference, notif)
				log.Info("Nr_Meas_Rep_Ue Notification" + "(" + subsIdStr + ")")