Re: [PHP4BETA] Databases and multithreading
| From: | Thies C. Arntzen | Date: | Sat, 09 Oct 1999 08:47:04 +0000 |
| Subject: | Re: [PHP4BETA] Databases and multithreading | ||
| References: | 1 | Groups: | php.version4 |
| Request: | Send a blank email to php-version4+get-5424@lists.php.net to get a copy of this message | ||
On Sat, 9 Oct 1999, Andreas Karajannis wrote:
> "Thies C. Arntzen" wrote:
> >
> >
> > nope - as plist is per-thread as well.
> >
> Just to clarify things: Does this mean plist is not really
> persistent and all data is lost after request shutdown?
not after request shutdown - but when the thread shutds down! all the
multi-threaded servers will reuse their threads for many reqests (like
MaxReqestPerChild in apache).
but again plist is *NOT* shared between processed - the good thing is we
don't have to mutex plist - the bad thing - we don't have an API yet for
sharing data (resources) beween threads!
>
> >
> > this should not really be an issue - question is if the db-libs are
> > thread-save and if they like to be initialized multiple times.
> >
> > if we want connection-pooling we need to think about something different
> > which can share data between threads.
> >
> Yes, there should be a central instance that hands out connections and
> handles concurrency - as aolserver does.
yep-
> We have to change the whole database connection mechanism or implement
> some clever list-based mechanism, which would minimize the impact on the
> various database modules.
i think the do_logon (list, plist, hashed_details etc) stuff in the
various db-modules is the most complicated part of the db-modules - i
think we'll have to do something about that soon(er or later)!
regards,
tc
>
> -Andreas
>
> --
> PHP 4 Beta
>
>
Thies C. Arntzen "One Big-Mac, Small Fries and a Coke!"
Digital Collections Phone +49 40 235350 Fax +49 40 23535180
Hammerbrookstr. 93 20097 Hamburg / Germany