Re: Why PHPLIB::DB sucks
| From: | Bertrand Mansion | Date: | Fri, 06 Jun 2003 08:17:19 +0000 |
| Subject: | Re: Why PHPLIB::DB sucks | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-17101@lists.php.net to get a copy of this message | ||
<borz_off@cs.msu.su> wrote :
> Alexey Borzov wrote:
>> I looked at PHPLIB's current CVS code and found out that PostgreSQL
>> driver *still* uses sequence emulation, while there are native sequences
>> in PostgreSQL (on which this 'emulation' relies internally!). As this
>> brain-damaged implementation wasn't fixed for the last several *years*
>> this also shows that hardly anyone uses PHPLIB.
> I looked a bit closer at the code and found out that this 'emulation' actually
> does not use native sequences at all. Instead it creates a table for all the
> sequences and locks it exclusively when a need to get a next id arises. This
> is
> even more brain-damaged, exclusive lock in PostgreSQL is usually acquired only
> by DROP TABLE, ALTER TABLE, CREATE INDEX and similar commands.
>
> This creates a bottleneck that will nullify all possible speed increases with
> this 'light' layer.
Isn't that the way they do it in PEAR::DB too ?
Bertrand Mansion
Mamasam