Events
Events are objects generated by probe and look like named list of attributes. Events can be monitored and analyzed with Hyperionix Entity State Machine and saved to EventChannel. Events can also include one or multiple entities. Events are created in probe callbacks using function Event
:
local event = Event(
-- event name
"My Event",
-- list of event attributes
{
foo = 1,
bar = "2"
}
)
EventChannel
EventChannel is a place where an event will be sent. Used as parameter of method send
of event object. This is the part of hp library. Currently the following event channels are supported:
file
- save event to events log file stored in Hyperionix installation directory;splunk
- save event to configured Splunk (https://www.splunk.com/) server;console
- dump event to console (use it only in local development with HDK);hpsvc
- send event to Hyperionix Service (enabled by default);esm
- send event to ESM in Hyperionix Service (enabled by default).local EventChannel = hp.EventChannel -- ... -- Send event to file and splunk channels. event1:send(EventChannel.file, EventChannel.splunk) -- .. -- Send event to file channel and don't send to ESM channel event2:send(EventChannel.file, -EventChannel.esm)
You can disable any channel for debugging or even forever prepending minus
-
to the channel.NOTE: Disabling
esm
andhpsvc
channels isn’t typical and you don’t need to do it in most cases.
For more examples check this part of our first probe tutorial.
For more hooks and probes check public repositories on github.