[asterisk-bugs] [JIRA] (ASTERISK-25040) pbx: Improve performance of reloads by making hint destruction more performant

Matt Jordan (JIRA) noreply at issues.asterisk.org
Thu Apr 30 10:20:32 CDT 2015


Matt Jordan created ASTERISK-25040:
--------------------------------------

             Summary: pbx: Improve performance of reloads by making hint destruction more performant
                 Key: ASTERISK-25040
                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-25040
             Project: Asterisk
          Issue Type: Improvement
      Security Level: None
          Components: Core/PBX
            Reporter: Matt Jordan


The PBX core maintains two hash tables for hints: a container of the
actual hints (hints), along with a container of devices that are watching that
hint (hintdevices). When a dialplan reload occurs, each hint in the hints
container is destroyed; this requires a lookup in the container of devices to
find the device => hint mapping object. In the current code, this performs an
ao2_callback, iterating over each of the device to hint objects in the
hintdevices container. For a large number of hints, this is extremely
expensive: dialplan reloads with 20000 hints could take several minutes
in just this phase.

This process could be made more efficient by storing the key of the device (its name) with the hint. This would prevent an expensive ao2_callback.



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list