Action Detector
Configuration reference for the service that triggers forensic and healing actions.
Action Detector#
Introduction#
Action Detector is a standalone microservice based on the Spring framework. This module triggers forensic and healing actions. Action-detector fetches all the required configurations from the Redis-Cluster.
Below are the functionalities of Action Detector:
Configuration Data: It uses hash names to get the configuration data.
Event handling: It handles KPIs and transaction violations.
Integration Points
- Input Queue: It receives data from the ‘anomaly-event-action-messages’ queue.
- Output Queue: It generates CommandRequestProtos and pushes it into the ‘command-messages’ queue.
You can run multiple Action Detectors.
Consul Keys#
The Action Detector module utilizes a set of consul keys designed to facilitate its configuration and operation. These keys are essential for the module to function correctly and efficiently.
The consul keys are as follows:
service/rabbitmq/hostname
service/rabbitmq/port
service/rabbitmq/username
service/rabbitmq/password
service/rabbitmq/sslenable
service/rabbitmq/sslprotocol
service/rabbitmq/anomalyactionsqueue
service/rabbitmq/commandmessagesqueue
service/redis/nodes
service/redis/sslenabled
service/forensic/workloadkpiwindowsizemin
service/forensic/behaviourkpiwindowsizemin
service/actiondetector/health/metrics/updateinterval/milliseconds
service/actiondetector/management/endpoints/web/exposure/include
service/actiondetector/management/endpoints/jmx/exposure/include
service/actiondetector/management/endpoints/health/enabled
service/actiondetector/jmx/enabled
service/actiondetector/loglevel
service/actiondetector/rootloglevel
service/actiondetector/auditlogs/maxfilesize
service/actiondetector/auditlogs/totalsizecap
service/actiondetector/auditlogs/maxhistory
service/actiondetector/logs/maxfilesize
service/actiondetector/logs/totalsizecap
service/actiondetector/logs/maxhistory
If you change the log level through these Consul keys, restart the module. To change the log level without a restart, see Change a Service's Log Level at Runtime.
Health Metrics#
The health metrics of the Action Detector are critical indicators used to monitor and ensure the optimal performance and reliability of the system.
| Metrics | Description |
|---|---|
| ReadQueueName | This is the name of the input queue. This queue is the same as the value for 'service/rabbitmq/anomalyactionsqueue' consul key. The initial value for this metric is 'anomaly-event-action-messages'. |
| WriteQueueName | This is the name of the output queue. This queue is the same as value for 'service/rabbitmq/commandmessagesqueue' consul key. The initial value for this metric is 'command-messages'. |
| ForensicsSuppressionTimeInMins | This is the time in minutes for forensics suppression. The initial value for this metric is 0. |
| RMQReads | This is the number of incoming messages from the queue corresponding to 'service/rabbitmq/anomalyactionsqueue' consul key. Initial value for this metric is 0. |
| RMQWrites | This is the number of outgoing messages to queue corresponding to 'service/rabbitmq/commandmessagesqueue' consul key. Initial value for this metric is 0. |
| RedisKeysNotAvailable | Action Detector reads data from Redis cache using Redis keys. If action detector does not receive data for any Redis key(s), value for this metric increases by 1. Initial value for this metric is 0. |
| Snapshots | This metric stores the number of incoming or outgoing messages to or from the queues corresponding to 'service/rabbitmq/anomalyactionsqueue' and 'service/rabbitmq/commandmessagesqueue' consul keys. It also stores the Redis keys that are not found in Redis cluster. Initial value for this metric is {}. Value of this metric resets periodically as per the value of 'service/actiondetector/health/metrics/updateinterval/milliseconds' consul key. |
| WorkerActiveSize | This is the total number of active threads. Initial value for this metric is 0. |
| WorkerPoolSize | This is the total number of threads in the pool. This is the maximum number of threads that can go in active state. Initial value for this metric is 0. |
| WorkerQueueSize | This is the total number of tasks present in the queue which are pending due to active threads count matching the pool size. Initial value for this metric is 0. |
| RmqReadDataErrors | This is the number of errors while Action Detector reads data from RabbitMQ. Initial value for this metric is 0. |
You can view the KPIs of HEAL modules such as the Action Detector in Control Center, and set thresholds for them at service level and instance level. See Set KPI thresholds for a service.