Re: [HACKERS] Hash index creation warning

2015-08-05 Thread Bruce Momjian
On Fri, Jun 26, 2015 at 11:40:27AM -0400, Robert Haas wrote: > On Wed, Jun 24, 2015 at 4:53 AM, Peter Geoghegan wrote: > > On Wed, Jun 24, 2015 at 1:45 AM, Craig Ringer wrote: > >> WARNING: hash indexes are not crash-safe, not replicated, and their > >> use is discouraged > > > > +1 > > I'm not

Re: [HACKERS] Hash index creation warning

2015-06-26 Thread Robert Haas
On Wed, Jun 24, 2015 at 4:53 AM, Peter Geoghegan wrote: > On Wed, Jun 24, 2015 at 1:45 AM, Craig Ringer wrote: >> WARNING: hash indexes are not crash-safe, not replicated, and their >> use is discouraged > > +1 I'm not wild about this rewording; I think that if users don't know what WAL is, they

Re: [HACKERS] Hash index creation warning

2015-06-26 Thread Robert Haas
On Wed, Jun 24, 2015 at 3:06 AM, Michael Paquier wrote: > On Wed, Jun 24, 2015 at 12:27 AM, Robert Haas wrote: >> I think you should be testing RelationNeedsWAL(), not the >> relpersistence directly. The same point applies for temporary >> indexes. > > Indeed. Patch updated attached. Committed.

Re: [HACKERS] Hash index creation warning

2015-06-24 Thread Peter Geoghegan
On Wed, Jun 24, 2015 at 1:45 AM, Craig Ringer wrote: > WARNING: hash indexes are not crash-safe, not replicated, and their > use is discouraged +1 -- Peter Geoghegan -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgr

Re: [HACKERS] Hash index creation warning

2015-06-24 Thread Craig Ringer
On 18 October 2014 at 02:36, Bruce Momjian wrote: > On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: >> David G Johnston writes: >> > The question is whether we explain the implications of not being WAL-logged >> > in an error message or simply state the fact and let the documentation >>

Re: [HACKERS] Hash index creation warning

2015-06-24 Thread Michael Paquier
On Wed, Jun 24, 2015 at 12:27 AM, Robert Haas wrote: > I think you should be testing RelationNeedsWAL(), not the > relpersistence directly. The same point applies for temporary > indexes. Indeed. Patch updated attached. -- Michael diff --git a/src/backend/commands/indexcmds.c b/src/backend/comma

Re: [HACKERS] Hash index creation warning

2015-06-23 Thread Robert Haas
On Mon, Jun 22, 2015 at 8:46 PM, Michael Paquier wrote: > On Tue, Jun 23, 2015 at 9:06 AM, Jim Nasby wrote: >> On 6/12/15 5:00 PM, Thom Brown wrote: >>> >>> On 18 October 2014 at 15:36, Bruce Momjian wrote: On Fri, Oct 17, 2014 at 02:36:55PM -0400, Bruce Momjian wrote: > > On F

Re: [HACKERS] Hash index creation warning

2015-06-22 Thread Michael Paquier
On Tue, Jun 23, 2015 at 9:06 AM, Jim Nasby wrote: > On 6/12/15 5:00 PM, Thom Brown wrote: >> >> On 18 October 2014 at 15:36, Bruce Momjian wrote: >>> >>> On Fri, Oct 17, 2014 at 02:36:55PM -0400, Bruce Momjian wrote: On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: > >

Re: [HACKERS] Hash index creation warning

2015-06-22 Thread Jim Nasby
On 6/12/15 5:00 PM, Thom Brown wrote: On 18 October 2014 at 15:36, Bruce Momjian wrote: On Fri, Oct 17, 2014 at 02:36:55PM -0400, Bruce Momjian wrote: On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: David G Johnston writes: The question is whether we explain the implications of no

Re: [HACKERS] Hash index creation warning

2015-06-12 Thread Thom Brown
On 18 October 2014 at 15:36, Bruce Momjian wrote: > On Fri, Oct 17, 2014 at 02:36:55PM -0400, Bruce Momjian wrote: >> On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: >> > David G Johnston writes: >> > > The question is whether we explain the implications of not being >> > > WAL-logged

Re: [HACKERS] Hash index creation warning

2014-10-18 Thread Bruce Momjian
On Fri, Oct 17, 2014 at 02:36:55PM -0400, Bruce Momjian wrote: > On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: > > David G Johnston writes: > > > The question is whether we explain the implications of not being > > > WAL-logged > > > in an error message or simply state the fact and le

Re: [HACKERS] Hash index creation warning

2014-10-17 Thread Bruce Momjian
On Fri, Oct 17, 2014 at 12:56:52PM -0400, Tom Lane wrote: > David G Johnston writes: > > The question is whether we explain the implications of not being WAL-logged > > in an error message or simply state the fact and let the documentation > > explain the hazards - basically just output: > > "hash

Re: [HACKERS] Hash index creation warning

2014-10-17 Thread Tom Lane
David G Johnston writes: > The question is whether we explain the implications of not being WAL-logged > in an error message or simply state the fact and let the documentation > explain the hazards - basically just output: > "hash indexes are not WAL-logged and their use is discouraged" +1. The

Re: [HACKERS] Hash index creation warning

2014-10-17 Thread David G Johnston
Bruce Momjian wrote > Now that we have the create hash index warning in 9.5, I realized that > we don't warn about hash indexes with PITR, only crash recovery and > streaming. This patch fixes that. > > Is the wording "cannot be used" too vague. The CREATE INDEX manual > page has the words "give

[HACKERS] Hash index creation warning

2014-10-17 Thread Bruce Momjian
Now that we have the create hash index warning in 9.5, I realized that we don't warn about hash indexes with PITR, only crash recovery and streaming. This patch fixes that. Is the wording "cannot be used" too vague. The CREATE INDEX manual page has the words "give wrong answers to queries", whic