res_pjsip_registrar.c: Update remove_existing AOR contact handling.

When "rewrite_contact" is enabled, the "max_contacts" count option can
block re-registrations because the source port from the endpoint can be
random.  When the re-registration is blocked, the endpoint may give up
re-registering and require manual intervention.

* The "remove_existing" option now allows a registration to succeed by
displacing any existing contacts that now exceed the "max_contacts" count.
Any removed contacts are the next to expire.  The behaviour change is
beneficial when "rewrite_contact" is enabled and "max_contacts" is greater
than one.  The removed contact is likely the old contact created by
"rewrite_contact" that the device is refreshing.

ASTERISK-27192

Change-Id: I64c107a10b70db1697d17136051ae6bf22b5314b
This commit is contained in:
Richard Mudgett
2017-09-20 18:36:15 -05:00
parent 39b68a41f7
commit d388c18abf
5 changed files with 192 additions and 21 deletions

View File

@@ -34,6 +34,13 @@ res_pjsip
unsolicited MWI NOTIFY requests and make them available to other modules via
the stasis message bus.
* The "remove_existing" option now allows a registration to succeed by
displacing any existing contacts that now exceed the "max_contacts" count.
Any removed contacts are the next to expire. The behaviour change is
beneficial when "rewrite_contact" is enabled and "max_contacts" is greater
than one. The removed contact is likely the old contact created by
"rewrite_contact" that the device is refreshing.
res_musiconhold
------------------
* By default, when res_musiconhold reloads or unloads, it sends a HUP signal