From:
Magnus Hagander <magnus(at)hagander(dot)net>
To:
Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc:
Euler Taveira de Oliveira <euler(at)timbira(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject:
Re: xlog location arithmetic
Date:
2012-02-25 12:23:25
Message-ID:
CABUevEwb8hS1Z7mnZjqbo8WBCe-XiSJ9UYXcWWrDo30qbFCm-g@mail.gmail.com (view raw or flat )
Thread:
2011-12-06 04:19:49 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2011-12-06 10:14:02 from Magnus Hagander <magnus(at)hagander(dot)net>
2011-12-06 16:11:32 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-06 18:00:51 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2011-12-06 18:06:36 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-13 17:48:22 from Jim Nasby <jim(at)nasby(dot)net>
2011-12-13 20:37:10 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-20 10:27:41 from Magnus Hagander <magnus(at)hagander(dot)net>
2011-12-20 13:08:50 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2011-12-23 11:54:22 from Magnus Hagander <magnus(at)hagander(dot)net>
2011-12-23 15:05:54 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-23 15:13:41 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-23 15:18:21 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-23 15:32:29 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-23 15:59:35 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2011-12-23 16:15:07 from Robert Haas <robertmhaas(at)gmail(dot)com>
2011-12-23 15:13:42 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-01-21 16:13:41 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-01-26 09:19:28 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-02-07 17:29:16 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-02-08 12:35:15 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-02-09 22:00:30 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-02-10 08:32:46 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-02-25 12:23:25 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-02-25 23:53:19 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-02-28 06:21:12 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-03-04 11:26:56 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-03-04 11:26:36 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-03-09 12:11:13 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-03-09 14:37:35 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 14:44:08 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-09 15:00:55 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 14:55:09 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 15:31:26 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-09 15:37:42 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 17:13:26 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-03-09 19:23:28 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2012-03-09 19:26:44 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 19:34:04 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-09 19:39:26 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-09 20:04:23 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 20:12:20 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-13 00:47:24 from Bruce Momjian <bruce(at)momjian(dot)us>
2012-03-13 02:51:50 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-03-13 03:03:42 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-13 03:36:45 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-03-09 19:37:43 from "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
2012-03-09 17:14:00 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-03-09 17:18:24 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-03-09 17:38:28 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-03-09 18:23:38 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-03-13 02:34:10 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-04-13 20:30:16 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-04-14 11:25:42 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-04-14 12:08:12 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-01-17 14:46:07 from Peter Geoghegan <peter(at)2ndquadrant(dot)com>
2011-12-06 17:39:21 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-01-14 14:06:34 from Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
2012-01-14 14:12:21 from Euler Taveira de Oliveira <euler(at)timbira(dot)com>
2012-01-15 01:18:31 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2012-01-15 03:49:00 from Gurjeet Singh <singh(dot)gurjeet(at)gmail(dot)com>
2012-01-15 04:44:08 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2012-01-15 08:17:54 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-01-15 08:37:30 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2012-01-15 08:45:25 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-01-16 17:57:25 from Robert Haas <robertmhaas(at)gmail(dot)com>
2012-01-16 17:58:29 from Magnus Hagander <magnus(at)hagander(dot)net>
2012-01-16 20:48:41 from Josh Berkus <josh(at)agliodbs(dot)com>
2012-01-16 21:10:23 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-16 21:25:50 from Josh Berkus <josh(at)agliodbs(dot)com>
2012-01-16 21:37:59 from Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
2012-01-16 22:08:09 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-16 22:25:50 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2012-01-16 22:40:38 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-17 15:33:27 from Matteo Beccati <php(at)beccati(dot)com>
2012-01-17 16:50:41 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-17 17:10:11 from Matteo Beccati <php(at)beccati(dot)com>
2012-01-17 17:22:12 from Matteo Beccati <php(at)beccati(dot)com>
2012-01-17 16:50:20 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-01-17 17:24:05 from Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
2012-01-17 20:17:05 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-18 01:23:13 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-18 02:46:36 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-22 18:53:39 from Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
2012-01-16 23:23:33 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-01-17 16:50:26 from Peter Eisentraut <peter_e(at)gmx(dot)net>
2012-01-17 18:19:13 from Greg Smith <greg(at)2ndQuadrant(dot)com>
2012-01-19 17:59:35 from Alex Shulgin <ash(at)commandprompt(dot)com>
2012-01-22 18:54:30 from Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
2012-01-19 18:14:02 from Andrew Dunstan <andrew(at)dunslane(dot)net>
2012-01-19 18:41:54 from Alex Shulgin <ash(at)commandprompt(dot)com>
2012-01-19 19:04:07 from Alvaro Herrera <alvherre(at)commandprompt(dot)com>
2012-01-19 19:10:00 from Andrew Dunstan <andrew(at)dunslane(dot)net>
Lists:
pgsql-hackers
On Fri, Feb 10, 2012 at 09:32, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
> On Fri, Feb 10, 2012 at 7:00 AM, Euler Taveira de Oliveira
> <euler(at)timbira(dot)com> wrote:
>> On 08-02-2012 09:35, Fujii Masao wrote:
>>
>> Fujii, new patch attached. Thanks for your tests.
>
> Thanks for the new patch!
>
>>> But another problem happened. When I changed pg_proc.h so that the unused
>>> OID was assigned to pg_xlog_location_diff(), and executed the above again,
>>> I encountered the segmentation fault:
>>>
>> I reproduced the problems in my old 32-bit laptop. I fixed it casting to
>> int64. I also updated the duplicated OID.
>
> Yep, in the updated patch, I could confirm that the function works fine without
> any error in my machine. The patch looks fine to me except the following minor
> comments:
I started working on this one to commit it, and came up with a few things more.
Do we even *need* the validate_xlog_location() function? If we just
remove those calls, won't we still catch all the incorrectly formatted
ones in the errors of the sscanf() calls? Or am I too deep into
weekend-mode and missing something obvious?
I've also removed tabs in the documentation, fixed the merge confllict
in pg_proc.h that happened during the wait, and fixed some indentation
(updated patch with these changes attached).
But I'm going to hold off committing it until someone confirms I'm not
caught too deeply in weekend-mode and am missing something obvious in
the comment above about validate_xlog_location.
--
Magnus Hagander
Me: http://www.hagander.net/
Work: http://www.redpill-linpro.com/
In response to
Responses
pgsql-hackers by date
Next :From: Thom BrownDate: 2012-02-25 12:42:00
Subject : Re: Command Triggers, patch v11
Previous :From : Thom BrownDate : 2012-02-25 12:07:36
Subject : Re: Command Triggers, patch v11