[Asterisk-code-review] taskprocessor: Enable subsystems and overload by subsystem (asterisk[16])

George Joseph asteriskteam at digium.com
Fri Feb 15 13:16:42 CST 2019


Hello Friendly Automation, 

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

    https://gerrit.asterisk.org/11002

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

Change subject: taskprocessor:  Enable subsystems and overload by subsystem
......................................................................

taskprocessor:  Enable subsystems and overload by subsystem

To prevent one subsystem's taskprocessors from causing others
to stall, new capabilities have been added to taskprocessors.

* Any taskprocessor name that has a '/' will have the part
  before the '/' saved as its "subsystem".
  Examples:
  "sorcery/acl-0000006a" and "sorcery/aor-00000019"
  will be grouped to subsystem "sorcery".
  "pjsip/distributor-00000025" and "pjsip/distributor-00000026"
  will bn grouped to subsystem "pjsip".
  Taskprocessors with no '/' have an empty subsystem.
  The "core show taskprocessors" CLI command now shows the subsystem.

* When a taskprocessor enters high-water alert status and it
  has a non-empty system, the subsystem name will be marked as
  "overloaded".

* When a taskprocessor leaves high-water alert status and it
  has a non-empty system, the subsystem name will be unmarked as
  "overloaded".

* A new api ast_taskprocessor_is_subsystem_overloaded() has been
  added that checks if a specific subsystem is overloaded.

* The pjsip distributor now uses
  ast_taskprocessor_is_subsystem_overloaded("pjsip") to determine
  if it should pause accepting new messages.

REMINDER: The taskprocessor code doesn't take any action itself based
on high-water alerts or overloading.  It's up to taskprocessor users
to check and take action themselves.  Currently only the pjsip
distributor does this.

Change-Id: I8c19068bb2fc26610a9f0b8624bdf577a04fcd56
---
M include/asterisk/taskprocessor.h
M main/stasis.c
M main/taskprocessor.c
M res/res_pjsip/pjsip_distributor.c
4 files changed, 97 insertions(+), 11 deletions(-)


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

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I8c19068bb2fc26610a9f0b8624bdf577a04fcd56
Gerrit-Change-Number: 11002
Gerrit-PatchSet: 2
Gerrit-Owner: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Friendly Automation (1000185)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20190215/49ff6a27/attachment.html>


More information about the asterisk-code-review mailing list