Changeset - 7b092b919f4f
[Not reviewed]
beta
0 6 0
Marcin Kuzminski - 13 years ago 2012-07-13 21:17:38
marcin@python-works.com
Switch to waitress wsgi server by default in rhodecode.
- waitress is fast, handles chunked encoding correctly (needed for git)
- waitress works on linux and windows
- it's now default because it can handle git properly out of the box.
6 files changed with 27 insertions and 24 deletions:
0 comments (0 inline, 0 general)
development.ini
Show inline comments
 
@@ -30,15 +30,16 @@ pdebug = false
 

	
 
[server:main]
 
##nr of threads to spawn
 
threadpool_workers = 5
 
#threadpool_workers = 5
 

	
 
##max request before thread respawn
 
threadpool_max_requests = 10
 
#threadpool_max_requests = 10
 

	
 
##option to use threads of process
 
use_threadpool = true
 
#use_threadpool = true
 

	
 
use = egg:Paste#http
 
#use = egg:Paste#http
 
use = egg:waitress#main
 
host = 0.0.0.0
 
port = 5000
 

	
 
@@ -47,7 +48,7 @@ use = egg:rhodecode
 
full_stack = true
 
static_files = true
 
# Optional Languages
 
# en, fr, pt_BR, zh_CN, zh_TW
 
# en, fr, ja, pt_BR, zh_CN, zh_TW
 
lang = en
 
cache_dir = %(here)s/data
 
index_dir = %(here)s/data/index
production.ini
Show inline comments
 
@@ -30,15 +30,16 @@ pdebug = false
 

	
 
[server:main]
 
##nr of threads to spawn
 
threadpool_workers = 5
 
#threadpool_workers = 5
 

	
 
##max request before thread respawn
 
threadpool_max_requests = 10
 
#threadpool_max_requests = 10
 

	
 
##option to use threads of process
 
use_threadpool = true
 
#use_threadpool = true
 

	
 
use = egg:Paste#http
 
#use = egg:Paste#http
 
use = egg:waitress#main
 
host = 127.0.0.1
 
port = 8001
 

	
 
@@ -47,7 +48,7 @@ use = egg:rhodecode
 
full_stack = true
 
static_files = true
 
# Optional Languages
 
# en, fr, pt_BR, zh_CN, zh_TW
 
# en, fr, ja, pt_BR, zh_CN, zh_TW
 
lang = en
 
cache_dir = %(here)s/data
 
index_dir = %(here)s/data/index
rhodecode/config/deployment.ini_tmpl
Show inline comments
 
@@ -30,15 +30,16 @@ pdebug = false
 

	
 
[server:main]
 
##nr of threads to spawn
 
threadpool_workers = 5
 
#threadpool_workers = 5
 

	
 
##max request before thread respawn
 
threadpool_max_requests = 10
 
#threadpool_max_requests = 10
 

	
 
##option to use threads of process
 
use_threadpool = true
 
#use_threadpool = true
 

	
 
use = egg:Paste#http
 
#use = egg:Paste#http
 
use = egg:waitress#main
 
host = 127.0.0.1
 
port = 5000
 

	
rhodecode/model/pull_request.py
Show inline comments
 
@@ -25,19 +25,17 @@
 

	
 
import logging
 
import binascii
 

	
 
from pylons.i18n.translation import _
 

	
 
from rhodecode.model.meta import Session
 
from rhodecode.lib import helpers as h
 
from rhodecode.model import BaseModel
 
from rhodecode.model.db import PullRequest, PullRequestReviewers, Notification,\
 
    ChangesetStatus
 
from rhodecode.model.db import PullRequest, PullRequestReviewers, Notification
 
from rhodecode.model.notification import NotificationModel
 
from rhodecode.lib.utils2 import safe_unicode
 

	
 
from rhodecode.lib.vcs.utils.hgcompat import discovery
 
from rhodecode.model.changeset_status import ChangesetStatusModel
 
from rhodecode.model.comment import ChangesetCommentsModel
 
from rhodecode.model.meta import Session
 

	
 
log = logging.getLogger(__name__)
 

	
setup.py
Show inline comments
 
@@ -33,6 +33,7 @@ __platform__ = platform.system()
 
is_windows = __platform__ in _get_meta_var('PLATFORM_WIN', _metadata)
 

	
 
requirements = [
 
    "waitress==0.8.1",
 
    "Pylons==1.0.0",
 
    "Beaker==1.6.3",
 
    "WebHelpers==1.3",
 
@@ -49,7 +50,7 @@ requirements = [
 
    "markdown==2.1.1",
 
    "docutils==0.8.1",
 
    "simplejson==2.5.2",
 
    "mock"
 
    "mock",
 
]
 

	
 
if sys.version_info < (2, 6):
test.ini
Show inline comments
 
@@ -30,15 +30,16 @@ pdebug = false
 

	
 
[server:main]
 
##nr of threads to spawn
 
threadpool_workers = 5
 
#threadpool_workers = 5
 

	
 
##max request before thread respawn
 
threadpool_max_requests = 2
 
#threadpool_max_requests = 2
 

	
 
##option to use threads of process
 
use_threadpool = true
 
#use_threadpool = true
 

	
 
use = egg:Paste#http
 
#use = egg:Paste#http
 
use = egg:waitress#main
 
host = 127.0.0.1
 
port = 5000
 

	
0 comments (0 inline, 0 general)