Return-Path: Delivered-To: apmail-perl-dev-archive@www.apache.org Received: (qmail 34399 invoked from network); 2 Dec 2004 10:57:17 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 2 Dec 2004 10:57:17 -0000 Received: (qmail 13139 invoked by uid 500); 2 Dec 2004 10:57:15 -0000 Delivered-To: apmail-perl-dev-archive@perl.apache.org Received: (qmail 13114 invoked by uid 500); 2 Dec 2004 10:57:15 -0000 Mailing-List: contact dev-help@perl.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Delivered-To: mailing list dev@perl.apache.org Received: (qmail 13086 invoked by uid 99); 2 Dec 2004 10:57:14 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from uk.radan.com (HELO styx.radan.com) (217.205.167.84) by apache.org (qpsmtpd/0.28) with SMTP; Thu, 02 Dec 2004 02:57:13 -0800 Received: from unknown(217.205.167.82) by styx.radan.com via csmap id 11f27b10_4451_11d9_980a_0002b3cb43e0_4651; Thu, 02 Dec 2004 10:58:16 +0000 (GMT) Received: from [172.16.51.16] (hdxp4.uk.radan.com [172.16.51.16]) by sockeye.uk.radan.com (8.9.1b+Sun/8.9.1) with ESMTP id KAA29451; Thu, 2 Dec 2004 10:54:16 GMT Message-ID: <41AEF4D5.4070504@uk.radan.com> Date: Thu, 02 Dec 2004 10:56:21 +0000 From: Steve Hay User-Agent: Mozilla Thunderbird 0.9 (Windows/20041103) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Stas Bekman CC: mod_perl Dev Subject: Re: plans for mp2.0.0 release schedule References: <41AE8C9D.1080003@stason.org> In-Reply-To: <41AE8C9D.1080003@stason.org> Content-Type: text/plain Content-Transfer-Encoding: 7bit X-NAIMIME-Disclaimer: 1 X-NAIMIME-Modified: 1 X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Stas Bekman wrote: >There are a few issues left, which are hopefully will be resolved shortly. > I have one big issue with porting my code to mp2 which I'm not sure if there's a resolution to? I'm currently running mp1 on Win32. The Perl interpreter used by mp1 on Win32 is single-threaded, which causes a bottleneck for busy sites because the Apache child threads serving responses have to fight over access to the single Perl thread available. However, we've found that it works perfectly well in practice on small intranet sites, and this is what we're using it for. If I switch to mp2 then the Perl interpreter is now multi-threaded, thus removing the performance bottleneck, which should be great except for one thing: All our mp code involves DBI (& DBD-mysql), but DBI is not thread-safe! I have a trivial DBI program (not involving mp at all) which crashes on Win32 with the delightful "free to wrong pool" error: use DBI; use threads; my $dsn = 'dbi:mysql:test'; my $usr = 'root'; my $pwd = undef; my $t = threads->new(\&dbsub); $t->join(); sub dbsub { my $dbh = DBI->connect($dsn, $usr, $pwd); $dbh->disconnect(); } When I posted this to the DBI users mailing list looking for a resolution, Tim Bunce's response was simply "Don't use threads". (http://www.mail-archive.com/dbi-users@perl.org/msg22595.html) So my expectation would certainly be that if I port my mp1 stuff to mp2 then it'll all break. Horribly. Is there a way to configure mp2 to build with a non-threaded Perl, or at least to run it in such a way as to not make use of the Perl interpreter's threads, in order to simulate mp1-style behaviour? I realise that re-introducing the performance bottleneck is not ideal, but at least I can live with it. (The other obvious solution of porting from Win32 to a decent OS is sadly not an option before anyone suggests it.) - Steve ------------------------------------------------ Radan Computational Ltd. The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only. If you have received this message in error or there are any problems, please notify the sender immediately. The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden. Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd. The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org For additional commands, e-mail: dev-help@perl.apache.org