[MXS-2959] Allow "alert" script to be executed when errors or warnings are logged Created: 2020-04-10 Updated: 2023-10-04 Resolved: 2023-10-04 |
|
| Status: | Closed |
| Project: | MariaDB MaxScale |
| Component/s: | N/A |
| Affects Version/s: | None |
| Fix Version/s: | N/A |
| Type: | New Feature | Priority: | Major |
| Reporter: | Chris Calender (Inactive) | Assignee: | Todd Stoffel (Inactive) |
| Resolution: | Won't Do | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||
| Description |
|
It would be a very useful feature if MaxScale could allow an "alert" script to be executed anytime errors or warnings are logged. The more granular this would be, the better (perhaps it could be a comma-delimited list of error/warning code values). To give an example, someone wants to be able to be notified immediately, via a script from MaxScale, when they see the following error ("Too many connections"):
|
| Comments |
| Comment by Johan Wikman [ 2020-04-14 ] | ||||||||
|
Perhaps this could be handled by this functionality: So the basic principle is that you can define the syslog facility and level that should be used when certain events are logged. If you use another facility than the one used by default, you will be able to easily pick these out from the syslog message stream. The underlying mechanism is generic, so if you can clearly define a particular event, it's possible to add support for it. | ||||||||
| Comment by markus makela [ 2022-07-18 ] | ||||||||
|
Using the streaming log API that already exists in MaxScale to implement it elsewhere should be pretty easy. Since it's a WebSocket, a simple Node.JS script could work:
|