Event queue

The event queue triggers events that are then picked up by notifications and script actions. Triggering an event does not use many system resources, so volume is not usually a problem. There are many events that are provided and triggered in the baseline system, so this queue will always contain activity.

The more important aspect of setting up scripts to send events to the event queue is making sure that the event is well-defined and only fires when it is supposed to. 

Well-explained events are much easier to use for other developers, so try to demonstrate what the event is triggered by in the name of the event itself, and certainly in the definition.

We can see a sample event log here:

Figure 10.13: Event log sample

In an event log, we can see when events were processed, and the processing duration of events. It is worth considering the impact of events taking a long time to process and, if necessary, investigate why this is the case.

In our example, we can see some regular events in the log including a successful login and established session, as well as a heartbeat event and text indexing.

When creating an event, ensure that you test edge-case scenarios so that the definition of the event truly reflects when it will fire.

When sending an event to the event queue for the more distant future, be careful that the event will not be lost as part of table rotation.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.86.134