Re: proposal: rounding up time value less than its unit. - Mailing list pgsql-hackers

From Tom Lane
Subject Re: proposal: rounding up time value less than its unit.
Date
Msg-id 2567.1408818170@sss.pgh.pa.us
Whole thread Raw
In response to Re: proposal: rounding up time value less than its unit.  (Tomonari Katsumata <t.katsumata1122@gmail.com>)
Responses Re: proposal: rounding up time value less than its unit.
List pgsql-hackers
Tomonari Katsumata <t.katsumata1122@gmail.com> writes:
> This patch rounds up the value when only it's less than required unit.
> ..
> Although my original complaint is fixed, I'm worried about this change will
> make users confusing.

Indeed.  I have not understood why you are insisting on "round up"
semantics.  Wouldn't it make more sense for the behavior to be "round to
nearest"?  That would get rid of any worries about treating zero specially.

> Is it better to raise a message(ex. INFO) when a value less than required
> unit is set?

No.  Non-error messages are probably completely useless in this area:
users will typically never see such messages for settings made in
postgresql.conf, because it will not occur to them to look in the
postmaster log.  So the behavior needs to be self-explanatory without
any messages; and that means it had better not be very complicated.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Craig Ringer
Date:
Subject: Re: Parallel Sequence Scan doubts
Next
From: David G Johnston
Date:
Subject: Re: proposal: rounding up time value less than its unit.