Skip to content

sirgalleto/node-ping-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Node Ping Server

NodeJS server to calculate the approximate ping from the browser to any server using web-sockets.

Aclaration

This is not a perfect ping calculation but I came to a good approximation improving the client flow.

Installation

  • $ git clone git@github.com:sirgalleto/ping-server.git
  • $ cd ping-server
  • $ npm install

Usage

  1. Run the service $ npm start.
  2. Create a socket connection to port 3500 (you can change the port creating a env var called PORT)
  3. Emit a ping2 event.
  4. Receive a pong2 event.
  5. Calculate the events interval.

About

NodeJS server to make pings from browser using web-sockets

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors