##// END OF EJS Templates
middleware: drop gzipper middleware...
Mads Kiilerich -
r6338:692dddf2 default
parent child Browse files
Show More
@@ -81,14 +81,13 b' Serve static files directly from the web'
81 81 -----------------------------------------------
82 82
83 83 With the default ``static_files`` ini setting, the Kallithea WSGI application
84 will take care of serving the static files found in ``kallithea/public`` from
85 the root of the application URL. While doing that, it will currently also
86 apply buffering and compression of all the responses it is serving.
84 will take care of serving the static files from ``kallithea/public/`` at the
85 root of the application URL.
87 86
88 The actual serving of the static files is unlikely to be a problem in a
89 Kallithea setup. The buffering of responses is more likely to be a problem;
90 large responses (clones or pulls) will have to be fully processed and spooled
91 to disk or memory before the client will see any response.
87 The actual serving of the static files is very fast and unlikely to be a
88 problem in a Kallithea setup - the responses generated by Kallithea from
89 database and repository content will take significantly more time and
90 resources.
92 91
93 92 To serve static files from the web server, use something like this Apache config
94 93 snippet::
@@ -104,9 +103,16 b' Then disable serving of static files in '
104 103 static_files = false
105 104
106 105 If using Kallithea installed as a package, you should be able to find the files
107 under site-packages/kallithea, either in your Python installation or in your
106 under ``site-packages/kallithea``, either in your Python installation or in your
108 107 virtualenv. When upgrading, make sure to update the web server configuration
109 108 too if necessary.
110 109
110 It might also be possible to improve performance by configuring the web server
111 to compress responses (served from static files or generated by Kallithea) when
112 serving them. That might also imply buffering of responses - that is more
113 likely to be a problem; large responses (clones or pulls) will have to be fully
114 processed and spooled to disk or memory before the client will see any
115 response. See the documentation for your web server.
116
111 117
112 118 .. _SQLAlchemyGrate: https://github.com/shazow/sqlalchemygrate
@@ -20,7 +20,6 b' from paste.cascade import Cascade'
20 20 from paste.registry import RegistryManager
21 21 from paste.urlparser import StaticURLParser
22 22 from paste.deploy.converters import asbool
23 from paste.gzipper import make_gzip_middleware
24 23
25 24 from pylons.middleware import ErrorHandler, StatusCodeRedirect
26 25 from pylons.wsgiapp import PylonsApp
@@ -105,7 +104,6 b' def make_app(global_conf, full_stack=Tru'
105 104 # Serve static files
106 105 static_app = StaticURLParser(config['pylons.paths']['static_files'])
107 106 app = Cascade([static_app, app])
108 app = make_gzip_middleware(app, global_conf, compress_level=1)
109 107
110 108 app.config = config
111 109
General Comments 0
You need to be logged in to leave comments. Login now