Skip to content

Instantly share code, notes, and snippets.

2 06:20
4 06:30
7 06:40
4 06:50
7 07:00
6 07:10
4 07:20
3 07:30
8 07:40
18 07:50
@zerodeux
zerodeux / gist:8803753
Created February 4, 2014 13:41
WSGI basic profiling middleware based on POSIX getrusage (simple mods from Gawel's)
__doc__ = """
Profiling middleware. Log wallclock, utime, stime and idle time.
Copy the file in your source tree and wrap your application with the RUsage
middleware::
from wsgi_profile import RUsage
application = WSGIAppilcation()
application = RUsage(application)