Tue Sep 25 13:53:22 PDT 2007
- Previous message: [Slony1-hackers] Re: XID in PG core/contrib
- Next message: [Slony1-hackers] Re: XID in PG core/contrib
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 9/25/2007 3:23 PM, Marko Kreen wrote: > On 9/25/07, Jan Wieck <JanWieck at yahoo.com> wrote: >> On 9/25/2007 1:58 PM, Marko Kreen wrote: >> > On 9/25/07, Jan Wieck <JanWieck at yahoo.com> wrote: >> >> txid_lt_snapshot() would then be txid_committed_before(int8, sn) and >> >> txid_gt_snapshot() respectively txid_committed_after(int8, sn). >> > >> > Considering one is NOT other, are both needed? >> > >> > I just think it's preferable to avoid duplications and >> > keep the API minimal. >> >> The same would apply to comparison operators. > is the same as NOT <= >> ... yet we prefer to have both available as it makes code more readable. > > Ok, if you insist. > > Still, how about better names? 'lt' and 'gt' are rather unfit > about the meaning of the operation. I think something like > txid_is_visible() is better. Plus txid_is_not_visible() then. > > Also txid_is_committed seems fine, but not as good. > If you don't like txid_committed_before/after, how about txid_visible_in_snapshot(int8,snap) txid_not_visible_in_snapshot(int8,snap) It's only names of functions that are very likely coded into programs rather than used interactively. So the length of the function name doesn't really matter. Jan -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #================================================== JanWieck at Yahoo.com #
- Previous message: [Slony1-hackers] Re: XID in PG core/contrib
- Next message: [Slony1-hackers] Re: XID in PG core/contrib
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Slony1-hackers mailing list