Re: About "Our CLUSTER implementation is pessimal" patch - Mailing list pgsql-hackers

From Tom Lane
Subject Re: About "Our CLUSTER implementation is pessimal" patch
Date
Msg-id 7942.1264087809@sss.pgh.pa.us
Whole thread Raw
In response to Re: About "Our CLUSTER implementation is pessimal" patch  (Takahiro Itagaki <itagaki.takahiro@oss.ntt.co.jp>)
Responses Re: About "Our CLUSTER implementation is pessimal" patch  (Takahiro Itagaki <itagaki.takahiro@oss.ntt.co.jp>)
List pgsql-hackers
Takahiro Itagaki <itagaki.takahiro@oss.ntt.co.jp> writes:
>  * I'd prefer to separate cost calculation routines from create_index_path()
>    and cost_sort(), rather than using a dummy planner.

Don't go that way.  The cost functions have enough dependencies on
low-level planner functionality that making them be standalone would be
a serious mess, both immediately and in terms of future maintenance.
(As an example, someday we'll probably get around to having cost_sort
actually look at the specific columns being sorted by, and that's
going to involve a lot of interaction with pathkeys.)

What I do think is that the quoted code snippet has no business being
outside the planner proper.  It'd be better to put it in planner.c
or someplace like that.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Andrew Chernow
Date:
Subject: Re: 8.5 vs. 9.0
Next
From: "Kevin Grittner"
Date:
Subject: Re: Streaming Replication and archiving