Memory question

3 views
Skip to first unread message

DarkBlue

unread,
May 4, 2007, 11:03:26 PM5/4/07
to TurboGears
Hi

tg 1.0.2.2
firebird 2.0
SO

I have following line in my kid file

<META HTTP-EQUIV="REFRESH" CONTENT="10"/>

every refresh of the page calls my controller

def index(self):
endID=0
startID=0
photocount=myphotocount()
startID=randint(1,photocount)
endID=startID+7
value1=startID
value2=endID
q='id>%s and id<%s' % (value1,value2)
photos=Photo.select(q,orderBy='-id')
return
dict(value1=value1,value2=value2,photos=photos,thumbnail=photos,photocount=photocount)


This perfectly displays 6 pictures from a large database
in a random fashion every 10 seconds.
(This is used for Intranet only)

However, the memory used is never released and after
a few hundred runs everything grinds to a halt.

The question is :
How to get the memory back after each refresh?
Is SO caching something ?


Db

Reply all
Reply to author
Forward
0 new messages