opEvents Event Panels are customisable views that allow you to create filtered perspectives of your event data. Each panel appears as an option in the Panels dropdown menu in the opEvents interface, giving quick access to these specialised event views.
Panels are configured in the /usr/local/omk/conf/EventsPanels.json
file. This file contains a JSON object where each key represents a unique panel configuration. You can define multiple panels within this single configuration file, and they will all appear in the Panels dropdown menu in the order they're defined.
This file will not exist on a fresh install.
{ "panel-identifier-1": { "title": "First Panel", "description": "Description of first panel", "model": "events", "filter": { "field": "filter_expression" } }, "panel-identifier-2": { "title": "Second Panel", "description": "Description of second panel", "model": "events", "filter": { "field": "filter_expression" } } } |
For example a panel with the name panel-identifier-1
will create a /omk/opEvents/panels/panel-identifier-1
Field | Type | Required | Description |
---|---|---|---|
| string | Yes | The display name of the panel shown as the title |
| string | Yes | Description of the panel shown in navigation |
| string | Yes | Data model to use (currently "events") |
| object | Yes | Collection of field:filter_expression pairs |
| string | No | If you wish to use custom table schema. See Customising Table Schemas |
The filter
object supports several types of matching, giving you flexibility in how you filter events. You can choose the matching method that best suits your needs:
For straightforward matches, simply provide the string you want to match:
{ "node-down-events": { "title": "Node Down Events", "description": "Shows all node down events", "model": "events", "filter": { "event": "Node Down" } } } |
When you need more complex pattern matching, you can use the regex:
or iregex:
prefixes:
regex:
- Case-sensitive regular expression matching
iregex:
- Case-insensitive regular expression matching
Example combining both simple and regex matching:
{ "sydney-critical": { "title": "Sydney Critical Events", "description": "Critical events from Sydney data centres", "model": "events", "filter": { "nodeinfo.configuration_location": "Sydney", // Simple string match "event": "iregex: (error|failure|outage)", // Case-insensitive pattern match "nodeinfo.configuration_role": "regex: server|router|switch" // Regex match } } } |
Exact value matches (e.g., state = "Up"
)
Specific locations (e.g., nodeinfo.configuration_location = "Melbourne"
)
Matching multiple possible values (e.g., regex: Error|Warning|Critical
)
Pattern matching (e.g., regex: Node[0-9]+Down
)
Case-insensitive searches (e.g., iregex: sydney|melbourne|brisbane
)
Complex text patterns (e.g., regex: ^SYD-[A-Z]{2}-[0-9]{3}$
)
Choose the simplest matching method that meets your needs. Simple string matching is more straightforward to understand and maintain, so use it when possible. Save regular expressions for when you need their pattern-matching power.
Some common filter examples to utilise:
“event”
: Event Name
“node”
: Node Name
“nodeinfo.configuration_group”
: Group
“nodeinfo.configuration_location”
: Location
“nodeinfo.configuration_customer”
: Customer
"nodeinfo.configuration_role"
: Role