Skip to content

karthik340/p2p-chat-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

p2p-chat-app

How to run app ?
go build
Run in first terminal ./chat
Run in second terminal ./chat -d (use multi address printed on first terminal)

Concepts related to p2p chat :

  1. we should append \n for every message as we are using it as delimiting character while reading it.
  2. S.close() used for closing stream.
  3. once a stream is opened , the object of stream should be used again and again untill it is closed. thats why we use for loop to stay on same stream for chat.
  4. In order to speak to other peer , our peer should add the multiaddress of first peer to its peer table.

About

chat app built on top of libp2p

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages