Caching control line

I was implemented a beaker with a cherry application, but after some requests the glass response time increases by about 10-14 seconds.

I think that after including from 500 to 1000 elements in the cache, the glass drops.

all cached types are simple (str, int, list, tuple, ...)

any idea?

+4
source share
1 answer

I found the problem The glass has some performance issues with the file type. I just changed

'cache.type' : 'file' 

in

 'cache.type' : 'dbm' 

and everything is so good !!!

when type is a file glass, the python pure pickle library is used to serialize the object. and brine is not suitable for large objects.

+7
source

Source: https://habr.com/ru/post/1345622/


All Articles