middleware Package¶
middleware Package¶
WSGI Middleware.
profile Module¶
Middleware that profiles the request with cProfile and displays profiling information at the bottom of each page.
-
class
galaxy.web.framework.middleware.profile.ProfileMiddleware(app, global_conf=None, limit=40)[source]¶ Bases:
objectMiddleware that profiles all requests.
All HTML pages will have profiling information appended to them. The data is isolated to that single request, and does not include data from previous requests.
-
galaxy.web.framework.middleware.profile.func_std_string(func_name)[source]¶ Match what old profile produced
remoteuser Module¶
Middleware for handling $REMOTE_USER if use_remote_user is enabled.
static Module¶
translogger Module¶
Middleware for logging requests, using Apache combined log format
-
class
galaxy.web.framework.middleware.translogger.TransLogger(application, logger=None, format=None, logging_level=20, logger_name='wsgi', setup_console_handler=True, set_logger_level=10)[source]¶ Bases:
objectThis logging middleware will log all requests as they go through. They are, by default, sent to a logger named
'wsgi'at the INFO level.If
setup_console_handleris true, then messages for the named logger will be sent to the console.-
format= '%(REMOTE_ADDR)s - %(REMOTE_USER)s [%(time)s] "%(REQUEST_METHOD)s %(REQUEST_URI)s %(HTTP_VERSION)s" %(status)s %(bytes)s "%(HTTP_REFERER)s" "%(HTTP_USER_AGENT)s"'¶
-
-
galaxy.web.framework.middleware.translogger.make_filter(app, global_conf, logger_name='wsgi', format=None, logging_level=20, setup_console_handler=True, set_logger_level=10)[source]¶ This logging middleware will log all requests as they go through. They are, by default, sent to a logger named
'wsgi'at the INFO level.If
setup_console_handleris true, then messages for the named logger will be sent to the console.