Skip to content

Latest commit

 

History

History
18 lines (12 loc) · 1.53 KB

File metadata and controls

18 lines (12 loc) · 1.53 KB

Multi-threaded WebServers tasks executor using WebHttpServer and WebServerSocket

This project aims to create two kinds of multi-threaded web servers (with thread-pooling) for executing simple tasks. There are three tasks implemented and the user can add more (see details below). The web servers receive the command and the parameter(s) for running a task through terminal command curl.

P.S. There is another project where I used ServerSocker in GitHub: localhost-chat-socket

Full article

Different Type of Web Serves Using HttpServer and ServerSocket

WebServers

  • WebServerHttp is developed using HttpServer [javadoc].

  • WebServerSocket is developed using ServerSocket [javadoc].

Both web servers use ExecutorService [javadoc] that executes each submitted task in the pooled thread, more specifically, Executors.newCachedThreadPool() which is an unbounded thread pool with automatic thread reclamation [javadoc].