[Zope-DB] Re: SQL Relay
mal at lemburg.com
Thu Oct 30 15:24:40 EST 2003
Kent Hoxsey wrote:
>>>The problem is that some of the SQL runs for a long time (1-2 minutes). Obviously,
>>>the load is on the database server, not the Zope server, so you would think the Zope
>>>server would be able to handle an amazing number of these requests.
That's an interesting view of "long time" :-)
>>Well, each Zope thread has to wait for the DB that it's accessing. Zope has 4
>>threads, by default, IIRC.
> As noted elsewhere, the 2-ZSQL-executing problem is unrelated to the number of
> Zope threads executing. Raising the number of threads (and the ZODB threads they
> depend upon) does not change the number of ZSQL methods that can execute at
> one time.
>>>that turns out not to be the case. Once Zope starts running the second long ZSQL,
>>>it effectively stops accepting requests until one of the two ZSQLs completes.
>>Hmm, that sounds like something somewhere is blocking... What database adapters
>>does this happen with? What adapters does it not happen with?
> My long-running queries go against very large tables in Oracle. I have encountered
> this problem with the DCOracle DA, ZODBCDA, mxODBCDA, SQLRelayDA, and straight
> python External Methods creating their own DCOracle database connections. As you
> might infer from the above list, the problem is the same on Linux and Win2k.
You have to be more specific about the kinds of queries you are running.
It is likely that they are imposing exclusive row locks on some of
the more important tables in your database. In that case, the problem
is not related to Zope, but a question of database and query design.
You would experience the same problem with any other software that
runs these queries in parallel.
Professional Python Software directly from the Source (#1, Oct 30 2003)
>>> Python/Zope Products & Consulting ... http://www.egenix.com/
>>> mxODBC, mxDateTime, mxTextTools ... http://python.egenix.com/
::: Try mxODBC.Zope.DA for Windows,Linux,Solaris,FreeBSD for free ! ::::
More information about the Zope-DB