Login | Register

Documentation

Documentation -> Manuals -> Manual devel -> Core Events

Pages for other versions: devel 3.3 3.2 3.1 Older versions: 3.0 2.4 2.3 2.2 2.1 1.11 1.10 1.9 1.8 1.7


Core Events v3.4
PrevNext

Events are exported by the OpenSIPS core through the Event Interface.


1.  Threshold limit exceeded 🔗

Event: E_CORE_THRESHOLD

This event is triggered when a particular action takes longer than a specific threshold. It can be raised when a MySQL or DNS query takes too long, or a SIP message processing goes beyond a specific limit. For more information please see this post.

Parameters:

  • source: the source of the event: mysql module, core (for DNS or message processing warnings).
  • time: the amount of time (in microseconds) spent by the operation
  • extra: extra information, depending on the source of the event

2.  Private memory threshold exceeded 🔗

Event: E_CORE_PKG_THRESHOLD

This event is triggered when the private memory usage goes above a threshold limit, specified by the event_pkg_threshold the core parameter. It warns external applications about low values of free private memory.

Parameters:

  • usage: the percentage of private memory usage. Can have values between event_pkg_threshold and 100.
  • threshold: the event_pkg_threshold specified in the script.
  • used: the amount of private memory used.
  • size: the total amount of private memory.
  • pid: the pid of the process that raises the event.

Note: If the event_pkg_threshold is not specified or 0, then this event is disabled.

3.  Shared memory threshold exceeded 🔗

Event: E_CORE_SHM_THRESHOLD

This event is triggered when the shared memory usage goes above a threshold limit, specified by the event_shm_threshold the core parameter. It warns external applications about low values of free shared memory.

Parameters:

  • usage: the percentage of private memory usage. Can have values between event_shm_threshold and 100.
  • threshold: the event_shm_threshold specified in the script.
  • used: the amount of private memory used.
  • size: the total amount of private memory.

Note: If the event_shm_threshold is not specified or 0, then this event is disabled.

4.  Process Auto-Scaling (upscale and downscale) 🔗

Event: E_CORE_PROC_AUTO_SCALE

This event is triggered whenever a new process is created (forked) or a process is terminated due the auto-scaling logic. In order to have this event trigger, the auto-scaling must be enabled in your configuration.

Parameters:

  • group_type: the type/name of the scaling group (UDP/TCP/TIMER).
  • group_filter: the filter (usually the socket/interface for UDP) of the scaling group.
  • group_load: the load over the scaling group.
  • scale: "up" or "down"
  • process_id: the process ID (at OpenSIPS level) of the scaled (up or down) process.
  • pid: the PID (OS level) of the scaled (up or down) process.

5.  TCP connection disconnected 🔗

Event: E_CORE_TCP_DISCONNECT

This event is triggered when a TCP connection is terminated/disconnected.

Parameters:

  • src_ip: the source IP of the TCP connection
  • src_port: the source PORT of the TCP connection
  • dst_ip: the destination IP of the TCP connection
  • dst_port: the destination PORT of the TCP connection
  • proto: the protocol of the underlying TCP connection ( ie. tcp, tls, ws, wss, etc )

6.  Status/Report status changed 🔗

Event: E_CORE_SR_STATUS_CHANGED

This event is triggered the status of an SR identifier changes.

Parameters:

  • group: the name of the SR group
  • identifier: the name of the SR identifier
  • status: the new status (as numerical value) of the SR identifier
  • details: the details/text attached to the new status
  • old_status: the old status (as numerical value) of the SR identifier


Page last modified on February 10, 2022, at 04:37 PM