On 2016-11-15 03:14, Mikhail Savushkin wrote: > Now we have another blocker on the road - the Pool building process is too > long to be fired on every request. And we cant afford collecting Pools for > all of the DBs in memory, since it will eat all the available memory pretty > quick.
Do you have measures for that? Maybe a solution will be to have a way to clear the pool for some database which were not accessed since a long time. > So we have an idea: rewrite a small part of the pool.py module, so > that it will build only the currently needed classes for the particular > request, i.e. patch the "Pool.get()" method mostly. And throw the data away > after request. So, we hope that building only a small part of all the > classes out there will cut the building time a lot, and will allow us to do > so on each request without significant response time lags. Some requests may require to access many classes in such case it will not be very efficient to build the class on the fly. Also to build a class, you need to query the database to know which modules are activated and build the dependency graph, so this will generate a lot of queries. -- Cédric Krier - B2CK SPRL Email/Jabber: cedric.kr...@b2ck.com Tel: +32 472 54 46 59 Website: http://www.b2ck.com/ -- You received this message because you are subscribed to the Google Groups "tryton-dev" group. To view this discussion on the web visit https://groups.google.com/d/msgid/tryton-dev/20161115121913.GL16659%40tetsuo.