-
Notifications
You must be signed in to change notification settings - Fork 611
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
[agw] [stateless MME] Fix for failing stateless AGW integration tests #3462
Conversation
hashtable_uint64_ts_destroy(s1ap_imsi_map_->mme_ue_id_imsi_htbl); | ||
|
||
free_wrapper((void**) &s1ap_imsi_map_); | ||
|
||
if (persist_state_enabled) { | ||
std::vector<std::string> keys_to_del; | ||
keys_to_del.emplace_back(S1AP_IMSI_MAP_TABLE_NAME); | ||
redis_client->clear_keys(keys_to_del); | ||
} | ||
} |
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.
is S1apStateManager::clear_s1ap_imsi_map()
called only during the service exit?
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.
Yes, it is only called at service exit, to clear all the memory allocated to the hashtable.
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.
LGTM
b6b90e4
to
93751f0
Compare
Signed-off-by: Shruti Sanadhya <ssanadhya@fb.com>
Signed-off-by: Shruti Sanadhya <ssanadhya@fb.com>
Signed-off-by: Shruti Sanadhya <ssanadhya@fb.com>
Signed-off-by: Shruti Sanadhya <ssanadhya@fb.com>
93751f0
to
70f0933
Compare
Merging despite Jenkins CI failures as those failures are unrelated to this change. |
…#3462) * Stop clearing s1ap_imsi_map from Redis * Re-adding stateless tests in sanity suite * Remove sleep from sctpd_post block in config_stateless_agw script * Commenting out data tests for stateless Signed-off-by: Shruti Sanadhya <ssanadhya@fb.com>
Summary
Running the test
test_attach_detach_with_<service>_restart.py
for mme or mobilityd multiple times in a row was showing a failure while trying to detach an attached UE. This was happening as thes1ap_imsi_map
table was getting cleared from Redis every time the MME process exited, leading to the error:Received S1AP UPLINK_NAS_TRANSPORT No UE is attached to this mme_ue_s1ap_id
This error only showed up for the second run of the test case even though each test case attaches/detaches two UEs. This is because the first UE detaches with detach-type "Normal detach", which triggered procedures to re-insert the entry in
s1ap_imsi_map
. Only for the second UE, which detached with detach-type "Switch-off" the map stays empty forever.This change fixes this issue by
Test Plan
test_attach_detach_with_mme_restart.py
multiple times and make sure the above error does not occur