Git Product home page Git Product logo

decentralizedgroupchat's Introduction

Gossip Protocol

A decentralized group chat with replication implemented using gossip protocol.

Gossip - Push Variant

Push gossip for disseminating information is implemented. Maintaining membership information, detecting failed nodes and sending group messages is implemented with the help of simple push gossip.

Gossip - Pull Variant

Pull gossip is implemented to maintain the consistency of delivering every message to each other. So when any node joins it will send pull requests to known nodes to get all the messages stored in there storage.

Exponential Backoff Algorithm

An exponential backoff algorithm is implemented to control the network congestion happening when gossip protocol is used to send messages. Exponential Backoff Algorithm controls the network traffic by not sending the same message to random nodes when a node gets the same message multiple times.

Requires maven - download[https://maven.apache.org/download.html] and install here[@https://maven.apache.org/install.html]

Run the below command to create jar file for the application

mvn clean install

  • The jar file will be created in target/GroupChat/GroupChat.jar. cd to it.

Run the below command to start the application, this opens the Initial Node.

java -jar .\GroupChat.jar 'Provide-your-IPAddress' 8080

Run the below command to start the other nodes.

java -jar .\GroupChat.jar 'Provide-your-IPAddress' 8081 'Provide-your-IPAddress' 8080

java -jar .\GroupChat.jar 'Provide-your-IPAddress' 8082 'Provide-your-IPAddress' 8081

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.