Skip to content

AWS MQ

AWS MQ (for RabbitMQ) supports industry-standard APIs and protocols, manages the management and maintenance of message brokers, and automatically provides infrastructure for high availability.

Configuration

Install Func

It is recommended to activate TrueWatch Integration - Extensions - DataFlux Func (Automata): All prerequisites are automatically installed, please proceed with the script installation.

If deploying Func manually, refer to Manual Deployment of Func

Install Script

Note: Please prepare an Amazon AK with the required permissions in advance (for simplicity, you can grant global read-only permissions ReadOnlyAccess).

Automata Activation Script

  1. Log in to the TrueWatch console.
  2. Click on the 【Integration】 menu and select 【Cloud Account Management】.
  3. Click on 【Add Cloud Account】, select 【AWS】, and fill in the required information on the interface. If you have already configured the cloud account information before, you can skip this step.
  4. Click on 【Test】. If the test is successful, click 【Save】. If the test fails, please check the relevant configuration information and test again.
  5. Click on the 【Cloud Account Management】 list to see the added cloud account. Click on the corresponding cloud account to enter the details page.
  6. Click on the 【Integration】 button on the cloud account details page. In the Not Installed list, find AWS MQ and click on the 【Install】 button. The installation interface will pop up for installation.

Manual Activation Script

  1. Log in to the Func console, click on 【Script Market】, enter the TrueWatch script market, and search for integration_aws_mq.

  2. Click on 【Install】, then enter the corresponding parameters: AWS AK ID, AK Secret, and account name.

  3. Click on 【Deploy Startup Script】. The system will automatically create a Startup script set and configure the corresponding startup scripts.

  4. After activation, you can see the corresponding automatic trigger configuration in 「Manage / Automatic Trigger Configuration」. Click on 【Execute】 to immediately execute it once without waiting for the scheduled time. Wait a moment, and you can view the execution task records and corresponding logs.

Verification

  1. In 「Manage / Automatic Trigger Configuration」, confirm whether the corresponding task has the automatic trigger configuration. You can also check the corresponding task records and logs for any anomalies.
  2. In TrueWatch, check if asset information exists in 「Infrastructure / Custom」.
  3. In TrueWatch, check if there is corresponding monitoring data in 「Metrics」.

Metrics

After configuring Amazon CloudWatch, the default measurement is as follows. More metrics can be collected through configuration:

Amazon CloudWatch AWS MQ Metrics Details

AWS MQ for RabbitMQ

Metric Name Unit Description
ExchangeCount Count The total number of exchanges configured on the broker.
QueueCount Count The total number of queues configured on the broker.
ConnectionCount Count The total number of connections established on the broker.
ChannelCount Count The total number of channels established on the broker.
ConsumerCount Count The total number of consumers connected to the broker.
MessageCount Count The total number of messages in the queue. The generated number is the sum of ready and unacknowledged messages on the broker.
MessageReadyCount Count The total number of ready messages in the queue.
MessageUnacknowledgedCount Count The total number of unacknowledged messages in the queue.
PublishRate Count The rate at which messages are published to the broker. The generated number represents the number of messages collected per second at the sampling time.
ConfirmRate Count The rate at which the RabbitMQ server confirms published messages. You can compare this metric with PublishRate to better understand your broker's performance. The generated number represents the number of messages collected per second at the sampling time.
AckRate Count The rate at which consumers acknowledge messages. The generated number represents the number of messages collected per second at the sampling time.
SystemCpuUtilization Percentage The percentage of allocated Amazon EC2 compute units currently in use by the broker. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes.
RabbitMQMemLimit Bytes The RAM limit for the RabbitMQ broker. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes.
RabbitMQMemUsed Bytes The RAM capacity used by the RabbitMQ broker. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes.
RabbitMQDiskFreeLimit Bytes The disk limit for the RabbitMQ broker. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes. This metric varies by instance size. For more information on AWS MQ instance types, refer to AWS MQ for RabbitMQ Instance Types.
RabbitMQDiskFree Bytes The total amount of free disk space available in the RabbitMQ broker. When disk usage exceeds its limit, the cluster will block all producer connections. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes.
RabbitMQFdUsed Count The number of file descriptors used. For cluster deployments, this value represents the sum of the corresponding metric values for all three RabbitMQ nodes.
RabbitMQIOReadAverageTime Count The average time (in milliseconds) for RabbitMQ to perform a read operation. This value is proportional to the message size.
RabbitMQIOWriteAverageTime Count The average time (in milliseconds) for RabbitMQ to perform a write operation. This value is proportional to the message size.