-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update handler.go #113
Update handler.go #113
Changes from 6 commits
7481562
b65603e
e65bdd9
edc094d
76557fc
735f795
dde7556
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -99,6 +99,9 @@ func SearchAmfCommunicationInstance(ue *amf_context.AmfUe, nrfUri string, target | |
// select the first AMF, TODO: select base on other info | ||
var amfUri string | ||
for _, nfProfile := range resp.NfInstances { | ||
if nfProfile.NfInstanceId == amf_context.GetSelf().NfId { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Was this check added because you got the current AMF as the query response from NRF? If that is the case, I think it is the query condition that has an issue to be fixed. (The exclusion check is fine and can be kept here since it is impossible to communicate with AMF itself. Just want to make sure if the codes of querying the target AMF is correct or not.) |
||
continue | ||
} | ||
ue.TargetAmfProfile = &nfProfile | ||
amfUri = util.SearchNFServiceUri(nfProfile, models.ServiceName_NAMF_COMM, models.NfServiceStatus_REGISTERED) | ||
if amfUri != "" { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be also considered for line 1234
callback.SendN1MessageNotifyAtAMFReAllocation(ue, n1Message.Bytes(), ®isterContext)
? Otherwise, will RegAceept be sent by the current AMF even when it requests for AMF Re-allocation?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Leon777-coder, Please add error return after line 1234.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't it what the line 1241 doing?
Whenever this handler reach the
needSliceSelection
state (which goes all the way down to the line 1234 if no error occurs), it willreturn nil
there (the line 1241). No further operation will be executed. Not to mentionRegAccept
in this situation.