Summary: | ASTERISK-28195: stasis: Don't create subscription change messages if noone cares | ||
Reporter: | Joshua C. Colp (jcolp) | Labels: | |
Date Opened: | 2018-12-05 07:33:03.000-0600 | Date Closed: | 2018-12-11 18:08:17.000-0600 |
Priority: | Minor | Regression? | No |
Status: | Closed/Complete | Components: | Core/Stasis |
Versions: | 13.23.1 16.0.0 | Frequency of Occurrence | |
Related Issues: | |||
Environment: | Attachments: | ||
Description: | As part of working on some statistics code I determined that for the most part Stasis messages in Asterisk are actually used - except for one: stasis_subscription_change_type. With filtering now a thing it seems as though about 50% of these messages aren't consumed by any subscriber.
This change is for making the creation smarter, so we only create those messages if a subscriber is interested in them. | ||
Comments: | By: Joshua C. Colp (jcolp) 2018-12-05 07:41:51.298-0600 Ideally whether a topic has any interested subscribers for these messages would be calculated ahead of time so the act of checking whether the messages need to be created is merely looking for a non-zero variable on the topic (to keep that fast). By: Joshua C. Colp (jcolp) 2018-12-11 18:08:17.814-0600 Unfortunately due to the usage of the subscription change message type for synchronization this isn't viable. We still need to create unsubscribes for that regardless. |