Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Deadlock with pg_dump?

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Simon Riggs <simon(at)2ndquadrant(dot)com>, Chris Campbell <chris(at)bignerdranch(dot)com>, pgsql-patches(at)postgresql(dot)org
Subject: Re: [HACKERS] Deadlock with pg_dump?
Date: 2007-03-02 20:20:27
Message-ID: 200703022020.l22KKRQ00125@momjian.us (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Tom Lane wrote:
> Bruce Momjian <bruce(at)momjian(dot)us> writes:
> > Are people going to be happy that log_statement and
> > log_min_duration_statement output the statement twice?
> 
> If those are the only cases you're worried about, a far simpler solution
> is to clear debug_query_string before instead of after emitting those
> log messages.

I am concerned about setting debug_query_string to NULL, calling
ereport(), and then resetting it might cause problems because of cases
where ereport might want to access debug_query_string for other uses,
for cases where ereport doesn't return to the reset code (but I assume
that is handled), and for cases like pgmonitor that would stop a
backend, read debug_query_string, and disconnect.

I can create a global variable to control this, but the new elog level
seemed cleaner.

-- 
  Bruce Momjian  <bruce(at)momjian(dot)us>          http://momjian.us
  EnterpriseDB                               http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

In response to

Responses

pgsql-hackers by date

Next:From: Bruce MomjianDate: 2007-03-02 20:20:58
Subject: Re: Final version of IDENTITY/GENERATED patch
Previous:From: Oleg BartunovDate: 2007-03-02 20:08:08
Subject: Re: Google SoC: lots of discussion, very few mentors

pgsql-patches by date

Next:From: Bruce MomjianDate: 2007-03-02 20:20:58
Subject: Re: Final version of IDENTITY/GENERATED patch
Previous:From: Zoltan BoszormenyiDate: 2007-03-02 19:55:25
Subject: Re: Final version of IDENTITY/GENERATED patch

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group