Skip to content

wma1729/webserver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A simple web server

Hash Requests are pushed on to a channel. The size of the channel is configurable via environment variable CHANNEL_SIZE. There are N worker threads waiting on the channel. The number of worker threads can be configured via environment variable NUM_OF_WORKERS.

On receiving the hash request, a unique id is generated and sent back to the client and the request is pushed into the channel. The worker threads pick up the request from the channel, wait if needed, and then compute the hashed password. A map of request ID -> hashed password is maintained.

On receiving the lookup request, the map is used to fulfil the request.

A global ServerStatistics is maintained to keep track of the number of requests received for stats endpoint.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages