valum-framework / valum

Web micro-framework written in Vala
https://valum-framework.readthedocs.io/en/latest/
GNU Lesser General Public License v3.0
225 stars 23 forks source link

Add nginx config files to SCGI & FastCGI examples #169

Open Bob131 opened 8 years ago

Bob131 commented 8 years ago

ref #161

Presenting: The World's Smallest Pull Request

arteymix commented 8 years ago

Is it possible to have standalone configuration with nginx?

Bob131 commented 8 years ago

Sure, but nginx can only read from one config file. That include setup is in the default nginx configuration

On Sat, Feb 20, 2016 at 1:17 AM, Guillaume Poirier-Morency notifications@github.com wrote:

Is it possible to have standalone configuration with nginx?

— Reply to this email directly or view it on GitHub.

arteymix commented 8 years ago

SCGI does not support UNIX domain sockets yet! (working on it!)

Unlike Lighttpd, nginx require quite a configuration to be usable. Providing just the sample is sufficient.

Maybe we should try to tune all the parameters? see how we can get the best out of Valum? it has a really impressive amount of settings.

Bob131 commented 8 years ago

You know what they say about preemptive optimization. I think it holds particularly true here where any attempt to optimize will improve performance in some instances but reduce performance in others. Honestly, I'm not sure I agree with the inclusion of these sample configs for nginx. It contains no information that doesn't appear on the first page of a Google result (and it ought not to because users will need to read the docs for themselves anyway to find a setup which works for them) and as such just provides extra data for bit rot.

Feel free to throw some suggestions out there if you find some options that should improve performance universally, but I don't know of any and if I did I would be reporting that as a bug since they seem to take the principle of sane defaults relatively seriously.

On Sun, Feb 21, 2016 at 3:25 PM, Guillaume Poirier-Morency notifications@github.com wrote:

SCGI does not support UNIX domain sockets yet! (working on it!)

Unlike Lighttpd, nginx require quite a configuration to be usable. Providing just the sample is sufficient.

Maybe we should try to tune all the parameters? see how we can get the best out of Valum? it has a really impressive amount of settings.

— Reply to this email directly or view it on GitHub.

arteymix commented 8 years ago

Maybe it would be more appropriate to update the docs then? It's pretty empty: http://docs.valum-framework.org/en/latest/vsgi/server/fastcgi/#nginx

There are a couple of buffer options, I say it could be interesting to suggest size that fit implementation internals.

I managed to test nginx a bit and it works really well! I found (and fixed) a couple of errors under heavy load.