Re: PITR Phase 2 - Design Planning

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PITR Phase 2 - Design Planning
Date: 2004-04-28 20:48:43
Message-ID: 1083185321.16467.15.camel@stromboli
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, 2004-04-28 at 18:35, Andrew Dunstan wrote:
> Simon Riggs wrote:
>
> >On Wed, 2004-04-28 at 05:00, Bruce Momjian wrote:
> >
> >
> >>What if we added transaction id to log_line_prefix? The user could then
> >>log all queries and find the xid where they want to stop, but of course
> >>that assumes they have enabled such logging, and they have access to the
> >>logs.
> >>
> >>
> >
> >Good thinking.
> >
> >I'll have a look at this and come back to you.
> >
> log_statement triggered logging happens very early in the process - if
> you are logging them all it happens before the statements are even
> parsed. Would we have an xid to log sensibly at that stage?
>
> Perhaps with log_min_duration_statment = 0 we would (i.e. log statements
> when finished rather than when started).
>

Let's call this XLogSpy.

For starters, we only need to look at write transactions. Many read-only
transactions would not need to be examined, just to know they were read
only.

Remembering that we're using xlogs for recovery, we perhaps should not
assume that we have anything other than that which has been archived.
Currently, that is just the xlogs. So really we need to work off what is
within them and right now that isn't much at all.

We might optionally include the parsed statement data into the xlog,
since this might be smaller than the exact text itself and would also
allow us to filter the xlogs based upon any aspect of the lists.

Not really happy with any of these ideas yet.

Best Regards, Simon Riggs

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Neil Conway 2004-04-28 23:22:10 Re: linked list rewrite
Previous Message Joshua D. Drake 2004-04-28 20:38:53 Re: [HACKERS] What can we learn from MySQL?