A question on pool-size
Hi all, I'm having a rather weird behavior configuring pool-size. I put a pool-size of 20 on two zeo-clients, but monitoring one of them I saw this on logs: 2007-06-26T16:47:02 WARNING ZODB.DB DB.open() has 19 open connections with a pool_size of 10 ------ 2007-06-26T16:47:02 WARNING ZODB.DB DB.open() has 20 open connections with a pool_size of 10 ------ 2007-06-26T16:47:02 CRITICAL ZODB.DB DB.open() has 90 open connections with a pool_size of 7 Sometimes it reported pool-size of 10, and sometimes it reported 7! What could this be? Another question: My expect a load of 50 concurrent requests, so I set zserver-threads to 25 on both zeo-clients, and a pool-size of 20 (but behaving as explained above). Do this conf make any sense? Where should I read to get more info about this matter? Best regards, Manuel. -- View this message in context: http://www.nabble.com/A-question-on-pool-size-tf3984717.html#a11313581 Sent from the Zope - General mailing list archive at Nabble.com.
Hello First, which Zope version do you have?
Sometimes it reported pool-size of 10, and sometimes it reported 7! What could this be? Maybe you're seeing warnings from few storages? but I'm not sure how this works an I have no idea why you're seeing pool sizes as 7 and 10 if you set this to 20....
Another question: My expect a load of 50 concurrent requests, so I set zserver-threads to 25 on both zeo-clients, and a pool-size of 20 (but behaving as explained above). Do this conf make any sense? Where should I read to get more info about this matter? I think it is better to use more Zeo clients than bump number of threads. There were some benchmarks (or sth like that) showing that bigger number of threads doesn't help too much to performance, and it may be even worse.
In your setup, if you have 25 threads you should have pool size bigger than 25 - every thread will possibly use ZODB so it should have connection to use. In fact connection is created as needed, even if pool_size is too small. That is why number of connections in your logs is bigger than pool_size. -- Maciej Wisniowski
Maciej, Zope is Zope 2.9.6 (2.9.6-4etch1 from Debian repo). I will try more zeo clients. Thanks for the tip. The thing that is bugging me is that it seems my configuration is not being taken into account. Is there an absolute limit for pool_size? Best regards, Manuel. Maciej Wisniowski wrote:
Hello
First, which Zope version do you have?
Sometimes it reported pool-size of 10, and sometimes it reported 7! What could this be? Maybe you're seeing warnings from few storages? but I'm not sure how this works an I have no idea why you're seeing pool sizes as 7 and 10 if you set this to 20....
Another question: My expect a load of 50 concurrent requests, so I set zserver-threads to 25 on both zeo-clients, and a pool-size of 20 (but behaving as explained above). Do this conf make any sense? Where should I read to get more info about this matter? I think it is better to use more Zeo clients than bump number of threads. There were some benchmarks (or sth like that) showing that bigger number of threads doesn't help too much to performance, and it may be even worse.
In your setup, if you have 25 threads you should have pool size bigger than 25 - every thread will possibly use ZODB so it should have connection to use. In fact connection is created as needed, even if pool_size is too small. That is why number of connections in your logs is bigger than pool_size.
-- Maciej Wisniowski _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
-- View this message in context: http://www.nabble.com/A-question-on-pool-size-tf3984717.html#a11314557 Sent from the Zope - General mailing list archive at Nabble.com.
The thing that is bugging me is that it seems my configuration is not being taken into account. Is there an absolute limit for pool_size?
Go to lib/python/ZODB/DB.py file There is a DB class with __init__ method. Put some print statements here to display pool_size and start zope with ./runzope or ./zopectl fg to see your prints. You may also take a look at 'push' method of _ConnectionPool in the same file. This is the place where warning messages came from. If you look closer then you'll see that there is no absolute limit for pool_size. Only warnings are printed. -- Maciej Wisniowski
participants (2)
-
Maciej Wisniowski -
Manuel Vázquez Acosta