On 10/24/07, John Siracusa <[EMAIL PROTECTED]> wrote:
> Well, if we trust register_cleanup() to clean up db connections and so on,
> why not trust it to reset globals too?
The problems I had involved unpredictable order of execution with
multiple cleanups. I'm fuzzy on the details though, since t
On 10/24/07 10:39 AM, Perrin Harkins wrote:
> In mod_perl 1, you can only store pnotes at a request level, so a
> subrequest has separate pnotes. This meant you would need to lookup
> the parent request ($r->main) to get your pnotes. In mod_perl 2, you
> have the option of using pnotes on a conne
On 10/23/07, John Siracusa <[EMAIL PROTECTED]> wrote:
> My problems were more along the lines of not realizing that an internal
> subrequest was happening, which (if memory serves) would end up clearing
> pnotes (or maybe my code was clearing/resetting pnotes when re-traversed for
> the subrequest)
On 10/23/07 6:42 PM, Arshavir Grigorian wrote:
> Does Rose::DB bypass Apache::DBI if connect_on_init() hasn't been called?
Rose::DB just calls DBI in a straightforward manner. It doesn't do anything
fancy. (Also, it's surprisingly hard to "bypass" Apache::DBI; it's not
something that will happen
On 10/23/07 5:17 PM, Perrin Harkins wrote:
> On 10/23/07, John Siracusa <[EMAIL PROTECTED]> wrote:
>> I've had some bad experiences with passing database handles around in
>> pnotes.
>
> It should be safe to do that. One thing to remember is that pnotes
> takes an alias to what you pass in, not a
On 10/23/07, Perrin Harkins <[EMAIL PROTECTED]> wrote:
> On 10/23/07, John Siracusa <[EMAIL PROTECTED]> wrote:
> > I've had some bad experiences with passing database handles around in
> > pnotes.
>
> It should be safe to do that. One thing to remember is that pnotes
> takes an alias to what you p
On 10/23/07, John Siracusa <[EMAIL PROTECTED]> wrote:
> I've had some bad experiences with passing database handles around in
> pnotes.
It should be safe to do that. One thing to remember is that pnotes
takes an alias to what you pass in, not a copy. If you feed it $foo
and then change the value
John Siracusa wrote:
>> Also, in my main handler, I do
>>
>> $r->pnotes(dbh => MSS::DB->new->dbh );
>
> I've had some bad experiences with passing database handles around in
> pnotes. You might want to try temporarily replacing that with with a
> global variable or something similarly tame just
On 10/23/07, Arshavir Grigorian <[EMAIL PROTECTED]> wrote:
> I just started using Rose::DB and have been experiencing certain
> database connectivity issues.
>
> DBD::Pg::st execute failed: ERROR: prepared statement "dbdpg_1" already
> exists
A quick google turned up this page which offers a pos