Skip to content

jbtrystram/dynamid-demo

Repository files navigation

Dynamid Demo

A simple demo built around Vert.x framework to showcase the usages and goals of modern middleware.

Architecture overview

Architecture overview

Distributed architecture

The aim of this setup is to showcase a fully distributed monitoring system. Every device (Raspberry-pi for example) hosts one component :

  • 1 temperature sensor
  • 1 AMQP broker
  • 1 mongoDB instance
  • 1 AMQP Vert.x connector

the others verticles are distributed among devices using the Vert.x built-in clustering function.

Setup

MongoDB cluster

To run the cluster locally (for testing), simply run

   cd mongoDBcluster
   docker-compose up 

To run it on the hosts, set up DNS or edit the /etc/hosts file, then :

   # Run on each host : 
   docker run  -p 27017:27017 -p 28017:28017 mongo:3.0 /usr/bin/mongod --replSet rs --smallfiles --rest --httpinterface
   
   # Then on only one host
   cd mongoDBcluster/setup/
   nano mongosetup.sh #change the hostnames or write down IPs
   docker build -t mongo-setup .
   docker run --rm mongo-setup 

To run the demo you have to sudo and execute from /demo:

# to compile all fat-jars
mvn clean package
# from each node
java -jar fatjars/demo-dynamid-Receiver-fat.jar -conf src/main/conf/demo.json
# in one of the nodes
java -jar fatjars/demo-dynamid-DataProcessor-fat.jar -ha -conf src/main/conf/demo.json
# in another node
java -jar fatjars/demo-dynamid-MongodbUpdater-fat.jar -ha -conf src/main/conf/demo.json
# from the grafana node
java -jar fatjars/demo-dynamid-GrafanaApi-fat.jar -conf src/main/conf/demo.json

About

Demo for the dynamid team at CITI lab

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published