Sign inSign up

robomq/monitor-ui

By robomq

•Updated almost 9 years ago

A real time dashboard including statistical detail that provides the pulse of the messaging activity

Image
1

204

robomq/monitor-ui repository overview

⁠Quick reference

⁠What is RoboMQ

RoboMQ⁠ is Hybrid Integration Platform⁠ (HIP) that is built to integrate IoT, SaaS applications, cloud and on premise systems in a truly distributed and highly scalable business workflows across networks and clouds. RoboMQ is built with Docker and microservices architecture for the enterprise applications and businesses of today. Key differentiation of RoboMQ are :

  1. Any-to-Any Integration⁠
  2. Microservices architecture⁠
  3. Hybrid Messaging Cloud⁠

RoboMQ⁠ provides added components on the top of core AMQP 0-9-1 broker based built on the strengths of rabbitmq⁠. RoboMQ offers added components that are built with message oriented middleware and microservices architecture. The core broker and all the value added components are packaged as docker containers. The value added components provide capabilities like Messaging dashboard, Quboid smart container, API gateway, API layer, Error Analytics and exception handlers, Event Logging, and health checks and on demand diagnostics, Mission Control.

⁠Monitor-UI RoboMQ Messaging Dashboard

Real time dashboard including statistical information that provides the pulse of the messaging activity, message rates, number of clients connections, messages in the queues, and the delivery and publish rates.

RoboMQ Messaging Dashboard is pre-configured and built upon Grafana, an open source metric analytics & visualization suite. It is most commonly used for visualizing time series data.

It has 2 important components.

  • InfluxDB storage
  • Messaging dashboard (Monitor-UI)

⁠1. Prerequisites

Ensure the following ports are open on the network for Monitor-ui and InfluxDB. Port 3000 is used to access messaging dashboard and InfluxDB port is used by application to get information from InfluxDB. If the broker runs behind a firewall which blocks these ports, you will need to either change firewall rules to unblock the ports, or switch to an available port permitted by firewall:

  • Messaging dashboard: 3000
  • InfluxDB HTTP API port: 8086

⁠2. Start an InfluxDB Storage

InfluxDB is a time series database built from the ground up to handle high write and query loads. It is the second piece of the TICK stack. InfluxDB is meant to be used as a backing store for any use case involving large amounts of timestamped data, including DevOps monitoring, application metrics, IoT sensor data, and real-time analytics.

The InfluxDB image exposes a shared volume under /var/lib/influxdb, so you can mount a host directory to that point to ensure container data is persisted similar to the RoboMQ broker setup above. The following command creates the InfluxDB container with persisted storage and creates an admin user required to allow access from the RoboMQ Monitor to store messaging data. See https://docs.docker.com/samples/library/influxdb/⁠ for full documentation.

⁠2.1 Run the InfluxDB container:
$ docker run --name=influxdb -d -p 8083:8083 -p 8086:8086 -e INFLUXDB_DB=System -e INFLUXDB_ADMIN_ENABLED=true -e INFLUXDB_ADMIN_USER=root -e INFLUXDB_ADMIN_USER=root123 -v <path-to-host>:/var/lib/influxdb influxdb:latest influxd
  • Replace < path-to-host > with desired path to mount from your host server
⁠2.2 Using the proveded HTTP API, create the spefified database where your broker messaging data will be stored to:
$ curl -XPOST http://root:root123@<your host IP>:8086/query --data-urlencode "q=CREATE DATABASE admin"
⁠2.3 Using the proveded HTTP API, create the specified user below granting this user read and write permissions for that database:
$ curl -XPOST http://root:root123@<your host IP>:8086/query --data-urlencode "q=CREATE USER admin WITH PASSWORD 'admin123'"

$ curl -XPOST http://root:root123@<your host IP>:8086/query --data-urlencode "q=GRANT READ on admin TO admin"

⁠3. Start a Messaging Dashboard (Monitor-UI)

The RoboMQ Messaging Dashboard image exposes a shared volume under /var/lib/grafana, so mount a host directory to that point to ensure container data is persisted similar to the RoboMQ broker and InfluxDB setup above. The following command creates the Monitor-ui container with volume mounted to host for persisted storage of your user and dashboard data.

$ docker run -d --name monitor-ui -p 3000:3000 -e INFLUXDB_HOST=<InfluxDB Host IP> -e INFLUXDB_PASSWORD=admin123 -v <path-to-host>:/var/lib/grafana --restart always robomq/monitor-ui:latest 

You can choose a different container name by changing theĀ --name option.

  • Replace < path-to-host > with desired path to mount from your host server
  • Replace < InfluxDB host IP > with the server host name or IP address hosting your InfluxDB container

⁠4. Provision User

Provision your Messaging Dashboard admin user for access to your messaging activity data.

$ docker exec -it monitor-ui sh -c 'provision_user.sh' 

You should see output similar to below indicating successful creation of your admin user dashboard.

HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8
Date: Fri, 22 Dec 2017 20:50:41 GMT
Content-Length: 33

{"id":2,"message":"User created"}

HTTP/1.1 200 OK
Content-Type: application/json; charset=UTF-8
Date: Fri, 22 Dec 2017 20:50:41 GMT
Content-Length: 52

{"id":1,"message":"Datasource added","name":"admin"}

HTTP/1.1 200 OK
Content-Type: application/json
Date: Fri, 22 Dec 2017 20:50:41 GMT
Content-Length: 55

{"slug":"administrator","status":"success","version":1}

⁠5. Accss the Messaging dashboard UI

URL : http://<your host IP>:3000
Login credential : admin/admin123

The web interface would look similar to below. If you initially do not see a dashboard button labeled "Administrator". There should be a drop down menu at the top left hand corner labeled "Home". Click that drop down and select "Administrator".

⁠6. Common management tasks

⁠6.1 Show status of the running monitor-ui container:
$ docker ps -f name=<container name> 

⁠6.2 Restart, stop, or remove listener
$ docker restart <container name> 

$ docker stop <container name> 

$ docker rm -v <container name> 
⁠6.3 View listener container logs
$ docker logs <container name> 

Tag summary

Content type

-

Digest

Size

301.1 MB

Last updated

almost 9 years ago

docker pull robomq/monitor-ui