Re: Transaction Wrapper and Perl 5.6.1

[prev] [thread] [next] [Date index for 2004/09/08]

From: Edward J. Sabol
Subject: Re: Transaction Wrapper and Perl 5.6.1
Date: 03:51 on 08 Sep 2004
>>> I'm trying to implement a custom trasaction subroutine in my program and
>>> I found out that "local $class->db_Main->{AutoCommit};" inside of
>>> do_transaction() subroutine caused memory leaks with Perl 5.6.1 from
>>> www.class-dbi.com site.
>>
>> I'm kind of locked into Perl 5.6.1 myself. My solution is to add
>> AutoCommit => 1 to all of my Class::DBI connection attributes. If you're
>> always in AutoCommit mode, then you don't need to "local
>> $class->db_Main->{AutoCommit};" in the do_transaction() method (just comment
>> that line out) and you won't leak memory.
>
> Thanks for help, Edward,
> However, if I am always in AutoCommit mode, how trasaction is going to 
> work?
> Is dbi_rollback and dbi_commit function sill working under AutoCommit mode?
> Thanks in advance..

I'm sorry. I meant to write "AutoCommit => 0" and "never in AutoCommit mode"
above. You'll have to explicitly commit everything, so, yes, dbi_rollback and
dbi_commit will work just fine in that scenario.

Transaction Wrapper and Perl 5.6.1
Stuart Johnston 22:12 on 01 Sep 2004

Re: Transaction Wrapper and Perl 5.6.1
Edward J. Sabol 08:34 on 02 Sep 2004

Re: Transaction Wrapper and Perl 5.6.1
young 15:22 on 02 Sep 2004

Re: Transaction Wrapper and Perl 5.6.1
Edward J. Sabol 03:51 on 08 Sep 2004

Re: Transaction Wrapper and Perl 5.6.1
Tony Bowden 18:27 on 02 Sep 2004

Re: Transaction Wrapper and Perl 5.6.1
young 18:54 on 02 Sep 2004

Generated at 11:34 on 01 Dec 2004 by mariachi v0.52