[Asterisk-code-review] stasis: No need to keep a stasis type ref in a stasis msg or... (asterisk[13])

Richard Mudgett asteriskteam at digium.com
Wed Sep 19 12:32:19 CDT 2018


Hello Jenkins2, George Joseph, Sean Bright, 

I'd like you to reexamine a change. Please visit

    https://gerrit.asterisk.org/10189

to look at the new patch set (#2).

Change subject: stasis: No need to keep a stasis type ref in a stasis msg or cache object.
......................................................................

stasis: No need to keep a stasis type ref in a stasis msg or cache object.

Stasis message types are global ao2 objects and we make stasis messages
and cache entries hold references to them.  Since there are currently
situations where cache objects are never deleted, the reference count on
the types can exceed 100000 and generate a FRACK assertion message.  The
stasis message cache could conceivably also have that many messages
legitimately on large systems.

The only down side to not holding the message type ref in the stasis
message is it only makes a crash either at shutdown or when manually
unloading a busy module slightly more likely.  However, this is more
exposing a pre-existing stasis shutdown ordering issue than a problem with
not holding a message type ref in stasis messages.

* Made stasis messages and cache entries no longer hold a ref to the
message type.

Change-Id: Ibaa28efa8d8ad3836f0c65957192424c7f561707
---
M main/stasis_cache.c
M main/stasis_message.c
2 files changed, 18 insertions(+), 4 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/89/10189/2
-- 
To view, visit https://gerrit.asterisk.org/10189
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ibaa28efa8d8ad3836f0c65957192424c7f561707
Gerrit-Change-Number: 10189
Gerrit-PatchSet: 2
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Sean Bright <sean.bright at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180919/221beee5/attachment.html>


More information about the asterisk-code-review mailing list