Re: Failed to request an autovacuum work-item in silence

2018-03-15 Thread Masahiko Sawada
On Thu, Mar 15, 2018 at 7:35 PM, Alvaro Herrera wrote: > Masahiko Sawada wrote: >> On Thu, Mar 15, 2018 at 12:06 AM, Alvaro Herrera >> wrote: > >> > Now I'm wondering what will we tell users to do if they get this message >> > too frequently.

Re: Failed to request an autovacuum work-item in silence

2018-03-15 Thread Alvaro Herrera
Masahiko Sawada wrote: > On Thu, Mar 15, 2018 at 12:06 AM, Alvaro Herrera > wrote: > > Now I'm wondering what will we tell users to do if they get this message > > too frequently. Neither of the obvious options (1. changing the index's > > pages_per_range to a larger

Re: Failed to request an autovacuum work-item in silence

2018-03-14 Thread Masahiko Sawada
On Thu, Mar 15, 2018 at 12:06 AM, Alvaro Herrera wrote: > Hello, > > Ildar Musin wrote: > >> autovac_get_workitem_name() declaration seems redundant and should be >> removed. The same thing with including "utils/lsyscache.h" in brin.c. >> >> The 'requested' variable in

Re: Failed to request an autovacuum work-item in silence

2018-03-14 Thread Alvaro Herrera
Hello, Ildar Musin wrote: > autovac_get_workitem_name() declaration seems redundant and should be > removed. The same thing with including "utils/lsyscache.h" in brin.c. > > The 'requested' variable in brininsert() I would again rename to something > like 'success' because a work item is

Re: Failed to request an autovacuum work-item in silence

2018-03-12 Thread Ildar Musin
Hi, autovac_get_workitem_name() declaration seems redundant and should be removed. The same thing with including "utils/lsyscache.h" in brin.c. The 'requested' variable in brininsert() I would again rename to something like 'success' because a work item is requested anyway but what matters

Re: Failed to request an autovacuum work-item in silence

2018-03-09 Thread Masahiko Sawada
Thank you for reviewing! On Thu, Mar 8, 2018 at 6:07 PM, Ildar Musin wrote: > Just couple remarks. I would rename 'requested' variable in > AutoVacuumRequestWork() func to something like 'success' or 'result'. > Because request is something caller does. And I would also

Re: Failed to request an autovacuum work-item in silence

2018-03-08 Thread Alvaro Herrera
Hi I was thinking that the BRIN code requesting the workitem would print the error message based on the return value. There is no point to returning a boolean indicator if the caller isn't going to do anything with it ... This means you don't need to convert the type to string in autovacuum.c

Re: Failed to request an autovacuum work-item in silence

2018-03-08 Thread Ildar Musin
Hello, The patch applies and compiles cleanly, tests pass. The code is working as well. I was able to check it by simply creating a BRIN index and filling the table with data forcing the index to request lots of work items: create table test (a serial, b text); create index on test using brin

Re: Failed to request an autovacuum work-item in silence

2018-03-01 Thread Masahiko Sawada
Thank you the comment. On Fri, Mar 2, 2018 at 4:18 AM, Alvaro Herrera wrote: > Masahiko Sawada wrote: > >> While reading the code, I realized that the requesting an autovacuum >> work-item could fail in silence if work-item array is full. So the >> users cannot realize

Re: Failed to request an autovacuum work-item in silence

2018-03-01 Thread Alvaro Herrera
Masahiko Sawada wrote: > While reading the code, I realized that the requesting an autovacuum > work-item could fail in silence if work-item array is full. So the > users cannot realize that work-item is never performed. > AutoVacuumRequestWork() seems to behave so from the initial >

Re: Failed to request an autovacuum work-item in silence

2018-03-01 Thread Andres Freund
Hi, On 2018-01-23 14:35:42 +0900, Masahiko Sawada wrote: > While reading the code, I realized that the requesting an autovacuum > work-item could fail in silence if work-item array is full. So the > users cannot realize that work-item is never performed. > AutoVacuumRequestWork() seems to behave

Re: Failed to request an autovacuum work-item in silence

2018-02-06 Thread Masahiko Sawada
On Thu, Jan 25, 2018 at 10:41 AM, Masahiko Sawada wrote: > On Thu, Jan 25, 2018 at 12:14 AM, Fabrízio de Royes Mello > wrote: >> >> >> On Wed, Jan 24, 2018 at 12:31 PM, Fabrízio de Royes Mello >> wrote: >>> >>> >>> >>> On

Re: Failed to request an autovacuum work-item in silence

2018-01-24 Thread Masahiko Sawada
On Thu, Jan 25, 2018 at 12:14 AM, Fabrízio de Royes Mello wrote: > > > On Wed, Jan 24, 2018 at 12:31 PM, Fabrízio de Royes Mello > wrote: >> >> >> >> On Tue, Jan 23, 2018 at 11:44 PM, Masahiko Sawada >> wrote: >> > >> > On

Re: Failed to request an autovacuum work-item in silence

2018-01-24 Thread Fabrízio de Royes Mello
On Tue, Jan 23, 2018 at 11:44 PM, Masahiko Sawada wrote: > > On Tue, Jan 23, 2018 at 8:03 PM, Fabrízio de Royes Mello > wrote: > > > > Em ter, 23 de jan de 2018 às 03:36, Masahiko Sawada < sawada.m...@gmail.com> > > escreveu: > >> > >> Hi all, > >>

Re: Failed to request an autovacuum work-item in silence

2018-01-23 Thread Masahiko Sawada
On Tue, Jan 23, 2018 at 8:03 PM, Fabrízio de Royes Mello wrote: > > Em ter, 23 de jan de 2018 às 03:36, Masahiko Sawada > escreveu: >> >> Hi all, >> >> While reading the code, I realized that the requesting an autovacuum >> work-item could fail in

Re: Failed to request an autovacuum work-item in silence

2018-01-23 Thread Fabrízio de Royes Mello
Em ter, 23 de jan de 2018 às 03:36, Masahiko Sawada escreveu: > Hi all, > > While reading the code, I realized that the requesting an autovacuum > work-item could fail in silence if work-item array is full. So the > users cannot realize that work-item is never performed. >

Failed to request an autovacuum work-item in silence

2018-01-22 Thread Masahiko Sawada
Hi all, While reading the code, I realized that the requesting an autovacuum work-item could fail in silence if work-item array is full. So the users cannot realize that work-item is never performed. AutoVacuumRequestWork() seems to behave so from the initial implementation but is there any