On Thu, Oct 7, 2010 at 7:20 AM, Shigeru HANADA
<hanada@metrosystems.co.jp> wrote:
> [ design for FDW ]
This seems mostly sensible.
> In this step, optimizer calls FdwRoutine->GetStatistics() to get
> estimated costs of the foreign scan. FDW can calculate costs by
> itself with some statistics, or get costs from remote-side, or leave
> the costs as is.
I think this should be called EstimateCosts rather than GetStatistics.
> Maybe DBAs want to see how much and what kind of connections are
> established now, so we should show list of active connections via a
> view or function. To treat connections transparently, I propose
> that connection pooling mechanism in the core module, not in each FDW
> module. Or should we add API to return list of active connections in
> common format?
I think for starters we should make this the responsibility of each
FDW. It seems a bit hard to speculate about what we might want down
the road at this point.
> Should we add API which is called from ANALYZE to allow FDWs to handle
> statistics when user wants.
I would probably put this off also, to a later phase of the project.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company