Re: [HACKERS] Hostnames in pg_hba.conf

2010-02-12 Thread Bart Samwel
On Fri, Feb 12, 2010 at 02:31, Mark Mielke wrote: > But once there, it seems clear that packing hostnames or netmasks onto one > line is just ugly and hard to manage. I'd like to see this extended to any > of the many ways to allow hostnames to be specified one per line. For > example: > > set t

Re: [HACKERS] Hostnames in pg_hba.conf

2010-02-11 Thread Bart Samwel
On Thu, Feb 11, 2010 at 23:01, Mark Mielke wrote: > On 02/11/2010 04:54 PM, Bart Samwel wrote: > > ISSUE #3: Multiple hostnames? >> >> Currently, a pg_hba entry lists an IP / netmask combination. I would >> suggest allowing lists of hostnames in the entries, so tha

Re: [HACKERS] Hostnames in pg_hba.conf

2010-02-11 Thread Bart Samwel
On Thu, Feb 11, 2010 at 17:21, Tom Lane wrote: > Bart Samwel writes: > > I've been working on a patch to add hostname support to pg_hba.conf. > > Have you read the previous discussions about that? > Yes, mostly. The previous discussions included all sorts of complex

Re: [HACKERS] Hostnames in pg_hba.conf

2010-02-11 Thread Bart Samwel
On Thu, Feb 11, 2010 at 16:36, Mark Mielke wrote: > On 02/11/2010 08:13 AM, Bart Samwel wrote: > ISSUE #2: Reverse lookup? > > There was a suggestion on the TODO list on the wiki, which basically said > that maybe we could use reverse lookup to find "the" hostname

[HACKERS] Hostnames in pg_hba.conf

2010-02-11 Thread Bart Samwel
Hi there, I've been working on a patch to add hostname support to pg_hba.conf. It's not ready for public display yet, but I would just like to run a couple of issues / discussion points past everybody. ISSUE #1: Performance / caching At present, I've simply not added caching. The reasoning for t

Re: [HACKERS] Avoiding bad prepared-statement plans.

2010-02-11 Thread Bart Samwel
On Thu, Feb 11, 2010 at 13:41, Robert Haas wrote: > On Thu, Feb 11, 2010 at 7:39 AM, Bart Samwel wrote: > > Anyhow, I have no clue how much time the planner takes. Can anybody > provide > > any statistics in that regard? > > It depends a great deal on the query, which i

Re: [HACKERS] Avoiding bad prepared-statement plans.

2010-02-11 Thread Bart Samwel
On Thu, Feb 11, 2010 at 13:25, Pavel Stehule wrote: > 2010/2/11 Bart Samwel : > > Perhaps this could be based on a (configurable?) ratio of observed > planning > > time and projected execution time. I mean, if planning it the first time > > took 30 ms and projected executi

Re: [HACKERS] Avoiding bad prepared-statement plans.

2010-02-11 Thread Bart Samwel
Hi Robert, On Tue, Feb 9, 2010 at 17:43, Robert Haas wrote: > On Tue, Feb 9, 2010 at 7:08 AM, Jeroen Vermeulen wrote: > > = Projected-cost threshold = > > > > If a prepared statement takes parameters, and the generic plan has a high > > projected cost, re-plan each EXECUTE individually with all