Home > Blockchain >  How to health check if ActiveMQ is working properly in asp.net core?
How to health check if ActiveMQ is working properly in asp.net core?

Time:09-04

How do you check the health of the ActiveMQ service?

public async Task<HealthCheckResult> CheckHealthAsync(HealthCheckContext context, CancellationToken cancellationToken = default(CancellationToken))
    {

        // Health Check ActiveMq Code?
        
        return HealthCheckResult.Healthy();
    }

CodePudding user response:

A best practice is to send a message and receive it. This verifies everything -- SSL, authentication, authorization, etc.

Especially, if you have a cluster. You can send one message to broker 1 of the cluster and consume it from broker 2 in the cluster.

  • Related