The Event Handling System (EHS) is a framework that allows operator-defined behavior to be configured on the router. EHS adds user-controlled programmatic exception handling by allowing the execution of either a CLI script or a Python 3 application when a log event (the ‟trigger”) is detected. Various fields in the log event provide regexp style expression matching, which allows flexibility for the trigger definition.
EHS handler objects are used to tie together the following:
trigger events (typically log events that match a configurable criteria)
a set of actions to perform (enabled using CLI scripts and Python applications)
EHS, along with CRON, may execute SR OS CLI scripts or Python 3 applications to perform operator-defined functions as a result of receiving a trigger event. The Python programming language provides an extensive framework for automation activities for triggered or scheduled events, including model-driven transactional configuration and state manipulation. See the Python chapter for more information.
The use of Python applications from EHS is supported only in model-driven configuration mode.
Figure: EHS object relationships shows the relationships among the different configurable objects used by EHS (and CRON).