summaryrefslogtreecommitdiff
path: root/include/asterisk
diff options
context:
space:
mode:
authorAlexei Gradinari <alex2grad@gmail.com>2016-08-08 13:53:32 -0400
committerAlexei Gradinari <alex2grad@gmail.com>2016-08-08 13:57:58 -0500
commit403b63571c53719bc050f4aded696cd933995d24 (patch)
treef12ba860945a4259979e2bb1d6497faf185304d7 /include/asterisk
parent9042ad40f2a56d6cfd4117897cbc9943253d4e09 (diff)
res_pjsip_mwi: fix unsolicited mwi blocks PJSIP stack
The PJSIP taskprocessors could be overflowed on startup if there are many (thousands) realtime endpoints configured with unsolicited mwi. The PJSIP stack could be totally unresponsive for a few minutes after boot completed. This patch creates a separate PJSIP serializers pool for mwi and makes unsolicited mwi use serializers from this pool. This patch also adds 2 new global options to tune taskprocessor alert levels: 'mwi_tps_queue_high' and 'mwi_tps_queue_low'. This patch also adds new global option 'mwi_disable_initial_unsolicited' to disable sending unsolicited mwi to all endpoints on startup. If disabled then unsolicited mwi will start processing on next endpoint's contact update. ASTERISK-26230 #close Change-Id: I4c8ecb82c249eb887930980a800c9f87f28f861a
Diffstat (limited to 'include/asterisk')
-rw-r--r--include/asterisk/res_pjsip.h26
1 files changed, 26 insertions, 0 deletions
diff --git a/include/asterisk/res_pjsip.h b/include/asterisk/res_pjsip.h
index 9bb2a82c5..cd6b33db4 100644
--- a/include/asterisk/res_pjsip.h
+++ b/include/asterisk/res_pjsip.h
@@ -2417,6 +2417,32 @@ int ast_sip_register_supplement(struct ast_sip_supplement *supplement);
void ast_sip_unregister_supplement(struct ast_sip_supplement *supplement);
/*!
+ * \brief Retrieve the global MWI taskprocessor high water alert trigger level.
+ *
+ * \since 13.12.0
+ *
+ * \retval the system MWI taskprocessor high water alert trigger level
+ */
+unsigned int ast_sip_get_mwi_tps_queue_high(void);
+
+/*!
+ * \brief Retrieve the global MWI taskprocessor low water clear alert level.
+ *
+ * \since 13.12.0
+ *
+ * \retval the system MWI taskprocessor low water clear alert level
+ */
+int ast_sip_get_mwi_tps_queue_low(void);
+
+/*!
+ * \brief Retrieve the global setting 'disable sending unsolicited mwi on startup'.
+ * \since 13.12.0
+ *
+ * \retval non zero if disable.
+ */
+unsigned int ast_sip_get_mwi_disable_initial_unsolicited(void);
+
+/*!
* \brief Retrieve the system debug setting (yes|no|host).
*
* \note returned string needs to be de-allocated by caller.