Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
38 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,38 @@ | ||
mojo-server-metyl | ||
================= | ||
Mojo-Server-Metyl | ||
================= | ||
|
||
Pure perl multi-threading webserver (based on ithreads) capable to run | ||
[Mojolicious](http://mojolicio.us/) applications. | ||
|
||
**BEWARE:** it's just a proof of concept, implemented only as a demo! | ||
|
||
**BEWARE:** it was tested with Mojolicious 3.42, however it is very likely | ||
that it will not work with future versions as it uses a hack into Mojolicious | ||
internals (not via public API). | ||
|
||
usage | ||
----- | ||
|
||
usage: metyl [OPTIONS] [APPLICATION] | ||
|
||
metyl script/mojoapp | ||
metyl /path/to/mojoapp.pl | ||
metyl -a 127.0.0.1 -p 80 mojoapp.pl | ||
|
||
These options are available: | ||
-a, --address <ip> Set IP adress you want to listen on (default: localhost) | ||
-p, --port <num> Set port number you want to listen on (default: 3000) | ||
-w, --workers <num> Set number of worker threads (default: 4) | ||
|
||
todo | ||
---- | ||
|
||
1. Hooking up threading vehicle to mojo's ioloop via event handler | ||
_Mojo::Reactor::recurring(0.5 => {...})_ is a bit suboptimal, | ||
perhaps having _Mojo::Reactor::idle_ can help | ||
|
||
2. There is no loadbalacning when assingning accepted sockets to | ||
worker threads. Even worse the used algorithm is a bit stupid as | ||
the first free worker takes all sockets currently available in | ||
the queue. | ||
|