Introduction
Log and show ram usage of a zope instance per request.
By calling @@requestlet, you’ll get a nice graph and (if you mark something in it) a table with ram usage, difference to the last request and the URI over time.
This product was created in the hope to see patterns on which requests how much ram is “lost”. It was inspired by http://code.google.com/p/zope-memory-readings/ and uses the graph-code from there.
The logging was taken from seletz’ requestlet code and was extended by the ram usage.
Installation / Usage
Add this to your buildout.cfg
[buildout] eggs = z3c.requestlet
[instance] zcml = z3c.requestlet
Then install the product using plone’s portal_quickinstaller. If the product is not installed, it will not log and it won’t provide the @@requestlet view.
After installation you may call
The default logfile is /tmp/requestlet.txt and may be set using an environment variable called “REQUESTLET_LOGNAME”.
You may also log only hits that take more than a specific time to render using an environment variable called “MIN_LOG_TIME”.
The logfile will provide detailled page generation information like this:
2009-07-01 16:21:39,755 requestlet INFO ELAPSED 0.038s (min 0s) METHOD GET RAM 423124kB URL: localhost:10054/site/++resource++z3c.requestlet.data/layout.css rinfo: last-modified=’Wed, 01 Jul 2009 12:51:28 GMT’ content-length=’169’ content-type=’text/css; charset=utf-8’ cache-control=’public,max-age=86400’
This provides:
time to render the page in plone (ELAPSED)
request method (METHOD)
total vmsize of the zope process (RAM)
the called URL (URL)
the request info (rinfo)
Compatibility
This product will only work with systems, where you can get the memory-info from /proc/<pid>/status. This is linux.
Contribution
To contribute, feel free to send patches as we don’t have this in a public svn currently. It’s managed with bzr ;)
Changelog
0.9.1 - Bugfix [20090706] [Daniel Kraft]
log as debug, not as info
0.9 - Initial useful release [20090701] [Daniel Kraft, Stefan Eletzhofer]
view ram usage per request
Metadata
Release files for z3c.requestlet 0.9.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| z3c.requestlet-0.9.1.tar.gz | 61.1 kB | Without provenance | Details |
Release files / z3c.requestlet-0.9.1.tar.gz
| Download URL | z3c.requestlet-0.9.1.tar.gz |
|---|---|
| Size | 61.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
910a9e3a442bfba0ba98fd2002a2e7c560a75f25e80fe696af61b40598f39260
|
|
BLAKE2b-256 checksum How to use checksums |
c9e750348ade4645410f5a5c081c115bb204f31142fbbc69e935b7d047c2fbdc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for z3c.requestlet 0.9.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.