comuniGO is a gRPC based P2P application developed in GO that supports both totally and causally ordered message delivery.
In the figure below L. Lamport, one of the main actors in Distribuited Systems field, S. Hykes, a co-founder of Docker.inc, and K. Thompson, a co-designer of GO programming language, communicate with each other using comuniGO
The application is based on three different components:
- The peer with whom you can interact via the web and internally uses gRPC to exchange messages with others
- The registration service with which you can sign yourself and receive the peer list
- The sequencer service necessary to implement the centralized totally ordered algorithm
So, thanks to the builder script it is possible to discriminate in fine grain what to build, in particular:
- You can use
-p
flag to build peer image - You can use
-r
flag to build registration service image - You can use
-s
flag to build sequencer image
as you can see running bash builder.bash -h
Before building and running the application, you can edit the configuration file to specify some environmental configuration settings.
After that you can use startup script to effectively startup peers and other components of the architecture.
As you can see running bash startup -h
there are a few options that permits you to further configure your experience with comuniGO, for example:
- You have to use
-n
flag to set the number of peers to spawn - You have to use
-t
flag to set the algorithm to use (sequencer
,scalar
orvectorial
) - You can use
-v
flag to enable verbose output on javascript console of your browser to see details of sent and/or received messages - You can use
-a
flag to enable attach mode indocker-compose up
To test appplication simply:
- Run the startup script as described above specifing which algorithm do you want to test
- Run the testing script specifing:
- The type of service to test (
sequencer
,scalar
orvectorial
), using-t
flag - The modality of the test (
single
ormultiple
), Using-m
flag
- The type of service to test (
- Finally, once collected results, you should shutdown components running
sh shutdown.sh
To use application simply follow one of this approach:
- Run discovery script to get links for peers' frontend
- Clone this repository and follow instructions inside the README file to achieve the same result
Enjoy comunication using comuniGO app and finally shutdown components running sh shutdown.sh
The project report is already available in the repository root (file: comunigo.pdf
).
Anyway if you want to compile it again, first you need to cd
into documentation folder and then run whatever tool you want for compiling .tex
files (e.g. pdflatex
, latexmk
, ...)
For instance:
- Using
latexmk
you can runlatexmk -pdf -silent comunigo.tex
- Using
pdflatex
you can runpdflatex comunigo.tex && pdflatex comunigo.tex
(twice for the resolution of references in the document)