Re: [HACKERS] One-Shot Plans

2011-08-01 Thread Simon Riggs
On Mon, Aug 1, 2011 at 6:39 PM, Tom Lane wrote: > Simon Riggs writes: >> One of the things I was looking at doing was allowing the operator >> estimation functions mark the plan as "one-shot" if they used >> non-uniform data to predict the estimate. That would require most >> functions to observe

Re: [HACKERS] One-Shot Plans

2011-08-01 Thread Tom Lane
Simon Riggs writes: > One of the things I was looking at doing was allowing the operator > estimation functions mark the plan as "one-shot" if they used > non-uniform data to predict the estimate. That would require most > functions to observe the rule that if a plan is marked unsafe then > nobody

Re: [HACKERS] One-Shot Plans

2011-08-01 Thread Simon Riggs
On Mon, Aug 1, 2011 at 4:55 PM, Tom Lane wrote: > Simon Riggs writes: >> On Tue, Jun 14, 2011 at 9:36 PM, Tom Lane wrote: >>> I have already got plans for a significantly more sophisticated approach >>> to this. > >> I'd like to move forwards on this capability in this release cycle. I >> want t

Re: [HACKERS] One-Shot Plans

2011-08-01 Thread Tom Lane
Simon Riggs writes: > On Tue, Jun 14, 2011 at 9:36 PM, Tom Lane wrote: >> I have already got plans for a significantly more sophisticated approach >> to this. > I'd like to move forwards on this capability in this release cycle. I > want to be able to tell whether a plan is a one-shot plan, or n

Re: [HACKERS] One-Shot Plans

2011-08-01 Thread Simon Riggs
On Tue, Jun 14, 2011 at 9:36 PM, Tom Lane wrote: > Simon Riggs writes: >> Currently, the planner and executor are mostly independent of each >> other: the planner doesn't really know when the plan will be executed, >> and the executor doesn't know how recently the plan was made. > >> We can work

Re: [HACKERS] One-Shot Plans

2011-06-20 Thread Jaime Casanova
On Tue, Jun 14, 2011 at 1:25 PM, Simon Riggs wrote: > > We can work out the various paths through the traffic cop to see when > a plan will be a "one-shot" - planned and then executed immediately, > then discarded. > > In those cases we can take advantage of better optimisations. Most > interestin

Re: [HACKERS] One-Shot Plans

2011-06-14 Thread Tom Lane
Simon Riggs writes: > Currently, the planner and executor are mostly independent of each > other: the planner doesn't really know when the plan will be executed, > and the executor doesn't know how recently the plan was made. > We can work out the various paths through the traffic cop to see when

Re: [HACKERS] One-Shot Plans

2011-06-14 Thread Bruce Momjian
Simon Riggs wrote: > On Tue, Jun 14, 2011 at 7:28 PM, Bruce Momjian wrote: > > Simon Riggs wrote: > >> Currently, the planner and executor are mostly independent of each > >> other: the planner doesn't really know when the plan will be executed, > >> and the executor doesn't know how recently the

Re: [HACKERS] One-Shot Plans

2011-06-14 Thread Simon Riggs
On Tue, Jun 14, 2011 at 7:28 PM, Bruce Momjian wrote: > Simon Riggs wrote: >> Currently, the planner and executor are mostly independent of each >> other: the planner doesn't really know when the plan will be executed, >> and the executor doesn't know how recently the plan was made. >> >> We can w

Re: [HACKERS] One-Shot Plans

2011-06-14 Thread Bruce Momjian
Simon Riggs wrote: > Currently, the planner and executor are mostly independent of each > other: the planner doesn't really know when the plan will be executed, > and the executor doesn't know how recently the plan was made. > > We can work out the various paths through the traffic cop to see when

[HACKERS] One-Shot Plans

2011-06-14 Thread Simon Riggs
Currently, the planner and executor are mostly independent of each other: the planner doesn't really know when the plan will be executed, and the executor doesn't know how recently the plan was made. We can work out the various paths through the traffic cop to see when a plan will be a "one-shot"