Package: grainbows
grainbow ‘Green Rainbows’ is a WSGI HTTP Server for UNIX, for sleepy application. It’s based onGunicornbut it’s designed to handle applications that expect long request/response times and/or slow clients. For other applications, you should use gunicorn, since it’s easier to debug.FeaturesDesigned forWSGIBuilt onGunicorn, inheriting its process/socket management features such as transparent upgrades and Python configuration DSL.Decode chunked transfers on-the-fly, allowing upload progress notifications or
stream-based protocols over HTTPSupport forEventletandGevent.ApplicationsWebsockets (seeexample), see thedemoReverse proxy implementation (withRestkit WSGI proxy)CometLong Polling…InstallGrainbows requires Python 2.x superior to 2.5.Install from sources:$ python setup.py installOr from Pypi:$ easy_install -U grainbowsBy default grainbows useGunicornarbiter, so you won’t have any benefits. You need to installEventletorGeventto use concurrency features.do:$ easy_install -U eventletReplaceeventletbygeventif you want to usegevent.Usagefor WSGI application:To launch theexample applicationpackaged with Grainbows:$ cd /path/to/grainbows/examples/
$ grainbows websocket:appand then go onhttp://localhost:8000to see the result.Note: by default the configuration is set to use eventlet. If you want to test with gevent, editgrainbows.conf.pyfile and replaceuse=”eventlet”byuse=”gevent”.The moduletest_keepalive:appspecifies the complete module name and WSGI callable. You can replace it with anything that is available on yourPYTHONPATHlike such:$ cd ~/
$ grainbows -c /path/to/configfile.py awesomeproject.wsgi.main:main_appFull command line usage:$ grainbows --help
Usage: grainbows [OPTIONS] APP_MODULE

Options:
  --use=USE             method to use (eventlet, gevent)
  -c CONFIG, --config=CONFIG
                        Config file. [none]
  -b BIND, --bind=BIND  Adress to listen on. Ex. 127.0.0.1:8000 or
                        unix:/tmp/gunicorn.sock
  -w WORKERS, --workers=WORKERS
                        Number of workers to spawn. [1]
  -p PIDFILE, --pid=PIDFILE
                        set the background PID FILE
  -D, --daemon          Run daemonized in the background.
  -m UMASK, --umask=UMASK
                        Define umask of daemon process
  -u USER, --user=USER  Change worker user
  -g GROUP, --group=GROUP
                        Change worker group
  -n PROC_NAME, --name=PROC_NAME
                        Process name
  --log-level=LOGLEVEL  Log level below which to silence messages. [info]
  --log-file=LOGFILE    Log to a file. - equals stdout. [-]
  -d, --debug           Debug mode. only 1 worker.
  --version             show program's version number and exit
  -h, --help            show this help message and exitForDjangoapplications use thegrainbows_djangocommand line and forPastecompatible applications (Pylons,TurboGears 2, …) usegrainbows_paste. See theusagepage on Gunicorn website for more information.Configuration fileA configuration file is needed to setupGrainbowsspecific settings. An example can be foundhereuse = "eventlet"
worker_connections = 1000You can also configure other settings, see theGunicorn configurationpage for more details.DevelopmentYou can get the source onGithub:http://github.com/benoitc/grainbows/And send your feedback onthe tracker.