|
Home > Archive > Apache Mod-Python > August 2006 > Updated: (MODPYTHON-184) Memory leak apache.table()
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Updated: (MODPYTHON-184) Memory leak apache.table()
|
|
| Graham Dumpleton (JIRA) 2006-08-25, 1:14 am |
| [ http://issues.apache.org/jira/brows...ON-184?page=all ]
Graham Dumpleton updated MODPYTHON-184:
---------------------------------------
Attachment: MP184-2006-08-25-grahamd-1.diff
Jim, can you test out this patch for the leak. It does away with tp_alloc altogether and tp_new simply calls MpTable_New(). I think this should be okay.
> Memory leak apache.table()
> --------------------------
>
> Key: MODPYTHON-184
> URL: http://issues.apache.org/jira/browse/MODPYTHON-184
> Project: mod_python
> Issue Type: Bug
> Components: core
> Affects Versions: 3.3, 3.2.10
> Reporter: Jim Gallacher
> Assigned To: Jim Gallacher
> Fix For: 3.3
>
> Attachments: MP184-2006-08-25-grahamd-1.diff
>
>
> There is a memory leak in apache.table().
> from mod_python import apache
> def handler(req):
> req.content_type = 'text/plain'
> t = apache.make_table()
> req.write('ok table:')
> return apache.OK
> Using mpm-worker with StartServers 2, and 20000 requests results in memory consumption going from 1.2% to 9.3% per process. (ie approx 8k per request)
> This will have an impact on FieldStorage which makes use of apache.make_table(), which is the deprecated name for apache.table()
| |
| Jim Gallacher 2006-08-25, 7:13 am |
| Graham Dumpleton (JIRA) wrote:
> [ http://issues.apache.org/jira/brows...ON-184?page=all ]
>
> Graham Dumpleton updated MODPYTHON-184:
> ---------------------------------------
>
> Attachment: MP184-2006-08-25-grahamd-1.diff
>
> Jim, can you test out this patch for the leak. It does away with tp_alloc altogether and tp_new simply calls MpTable_New(). I think this should be okay.
I'll test it, but I may not get to it today. Tomorrow for sure though.
If your patch fixes this leak I think we should proceed with a dev
snapshot - a kind of 3.3.x alpha release. 
Jim
>
|
|
|
|
|