[OpenSIPS-Devel] [OpenSIPS/opensips] 21b84c: Added new status/report framework.

Bogdan Andrei IANCU noreply at github.com
Tue Feb 8 15:55:10 UTC 2022


  Branch: refs/heads/master
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 21b84ccc77bd48fe885536cf423ec394a8893ba7
      https://github.com/OpenSIPS/opensips/commit/21b84ccc77bd48fe885536cf423ec394a8893ba7
  Author: Bogdan-Andrei Iancu <bogdan at opensips.org>
  Date:   2022-02-08 (Tue, 08 Feb 2022)

  Changed paths:
    M core_cmds.c
    M daemonize.c
    M daemonize.h
    M main.c
    M mi/mi_core.c
    M modules/dispatcher/dispatch.c
    M modules/mid_registrar/save.c
    M modules/usrloc/dlist.c
    M shutdown.c
    M signals.c
    A status_report.c
    A status_report.h

  Log Message:
  -----------
  Added new status/report framework.

The purpose of this framework is to allow Modules (or parts of the core) to register identifiers in order to publish their status (readiness) and reports (logs).
There statuses/reports may be checked from scripts or listed via MI. This allow the script to check the readiness status of various components of OpenSIPS, or, an external entity may monitor (check, list, get events) of the status / readiness of OpenSIPS (or parts of it). Also reports (some important logs poduced by OpenSIPS/modules) may be listed via MI, in order to have some history of what happened inside OpenSIPS/modules.

Available cfg commnds (core provided):
	sr_check_status( group, [identifier])

Available MI commands (core providede):
	sr_get_status group identifier
	sr_list_status [group]
	sr_list_reports [group] [identifier]

Available events (core provided):
	E_SR_STATUS_CHANGED ( group, identifier, new_status, new_details, old_status)

The old "general" OpenSIPS status was ported to this new framework as group "core", identifier "main", publishing the core status (startup, running, terminating).





More information about the Devel mailing list