[mod_python] Keeping data in memory

Graham Dumpleton graham.dumpleton at gmail.com
Tue Feb 9 19:12:21 EST 2010

True. As described in:


if you want cross process sharing, you can't rely on global variables
and must use an out of process storage mechanism.


2010/2/9 Primožič Boštjan <bostjan.primozic at amis.net>:
> It works with global variables, but if there is more than one thred/instance
> of interpreter there will be problems.
>> Hi,
>> I'd like to know if it's possible and how to store some data in memory.
>> I get small amount of date by parsing some other pages and this takes
>> relativly long time, so I want to keep this data in memory ( if posible ).
>> I
>> heared something about storing this data in "global" variable which stays
>> in
>> memory all the time.
> Have you actually tried using Google to search for 'Python global
> variables'.
> http://www.google.com/search?client=safari&rls=en&q=python+global+variables&ie=UTF-8&oe=UTF-8
> Understand what global variables are in Python and you have your answer.
> Graham

More information about the Mod_python mailing list