On Sun, May 3, 2009 at 7:31 AM, Syed Ali <[email protected]> wrote: > > How much memory are you giving to it? And how big are your objects? > > It could be that they get evicted to make space for new ones....and > therefore you dont find them in cache
it appears from his description that he uses the same key - so when it is paced - there is a cache-hit because the first request would have populated the cache with the key. when he tries to race - obviously all threads face the same truth - the looked up object is absent - so they all try to replenish the missing object hence goes to db simultaneously, -regards -pallab > > > > Memcache is built for high traffic and absolutely would not have any > problems with such low number of items/transactions > > > > On 5/3/09, Pallab Bhattacharya <[email protected]> wrote: > > On Thu, Apr 30, 2009 at 8:45 PM, scorpio <[email protected]> wrote: > > > >> > >> Ok, so I have my Django app. and memcache (also installed cmemcache) > >> running on 1 server and the db running on another server. > >> When I do say, 10 read or write requests to the cache, wait for > >> response and then do 10 more everything is fine. Now, if I "overload" > >> the caching mechanism by doing 5 of these 10 requests in a row, > >> without waiting for them to complete, the cache "breaks"...ie cannot > >> do the usual and valid write/read requests...it will always go to the > >> db. > > > > so what should happen on a cache miss? > > > > > >> > >> This is all fixed after restarting apache and going at a slow pace > >> again (10 at a time) and so on. > >> Any thoughts on what this caching issue might be? > > > > > -- > Best, > - Ali >
