From: | Julien Rouhaud <rjuju123(at)gmail(dot)com> |
---|---|
To: | Dilip Kumar <dilipbalaut(at)gmail(dot)com> |
Cc: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Justin Pryzby <pryzby(at)telsasoft(dot)com>, Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Kirill Bychik <kirill(dot)bychik(at)gmail(dot)com>, Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> |
Subject: | Re: User Interface for WAL usage data |
Date: | 2020-04-03 13:42:40 |
Message-ID: | CAOBaU_YWyXcazB1hWWcZOeYPL2wO7fMb7RMweCkPwUwn43D5zQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Apr 3, 2020 at 11:58 AM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
>
> On Fri, Apr 3, 2020 at 1:57 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> >
> > On Fri, Apr 3, 2020 at 11:29 AM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> > >
> > > On Fri, Apr 3, 2020 at 11:14 AM Justin Pryzby <pryzby(at)telsasoft(dot)com> wrote:
> > > >
> > > > On Fri, Apr 03, 2020 at 10:52:02AM +0530, Amit Kapila wrote:
> > > > > On Fri, Apr 3, 2020 at 10:41 AM Justin Pryzby <pryzby(at)telsasoft(dot)com> wrote:
> > > > > >
> > > > > > > > > > > > WAL: records=2359 full page records=42 bytes=447788
> > > > > >
> > > > > > 1) records; 2) pages ("full page images"); 3) bytes
> > > > > >
> > > > > > That is exactly like sort (method/type/size) and hash (buckets/batches/size),
> > > > > > and *not* like buffers, which shows various values all in units of "pages".
> > > > > >
> > > > >
> > > > > The way you have written (2) appears to bit awkward. I would prefer
> > > > > "full page writes" or "full page images".
> > > >
> > > > I didn't mean it to be the description used in the patch or anywhere else, just
> > > > the list of units.
> > > >
> > > > I wonder if it should use colons instead of equals ? As in:
> > > > | WAL: Records: 2359 Full Page Images: 42 Size: 437kB
> > > >
> > > > Note, that has: 1) two spaces; 2) capitalized "fields"; 3) size rather than
> > > > "bytes". That's similar to Buckets:
> > > > | Buckets: 1024 Batches: 1 Memory Usage: 44kB
> > > >
> > > > I'm not sure if it should say "WAL: " or "WAL ", or perhaps "WAL: " If
> > > > there's no colon, then it looks like the first field is "WAL Records", but then
> > > > "size" isn't as tightly associated with WAL. It could say:
> > > > | WAL Records: n Full Page Images: n WAL Size: nkB
> > > >
> > > > For comparison, buffers uses "equals" for the case showing multiple "fields",
> > > > which are all in units of pages:
> > > > | Buffers: shared hit=15 read=2006
> > > >
> > >
> > > I think this is more close to the case of Buffers where all fields are
> > > directly related to buffers/blocks. Here all the fields we want to
> > > display are related to WAL, so we should try to make it display
> > > similar to Buffers.
> > >
> >
> > Dilip, Julien, others, do you have any suggestions here? I think we
> > need to decide something now. We can change a few things like from
> > 'two spaces' to 'one space' between fields later as well.
>
> I also think it is more close to the BufferUsage so better to keep
> similar to that.
+1 too for keeping consistency with BufferUsage, and adding extra
spaces if needed.
> If we think the parsing is the problem we can keep
> '_' in the multi-word name as shown below.
> WAL: records=n full_page_writes=n bytes=n
I'm fine with it too.
To answer Justin too:
> Also, for now, the output can be in kB, but I think in the future we should
> take a recent suggestion from Andres to make an ExplainPropertyBytes() which
> handles conversion to and display of a reasonable unit.
This could be nice, but I think that it raises some extra concerns.
There are multiple tools that parse those outputs, and having to deal
with a new and non-fixed units may cause some issues. And probably
the non text output would also need to be displayed differently.
From | Date | Subject | |
---|---|---|---|
Next Message | James Coleman | 2020-04-03 13:49:44 | Re: Nicer error when connecting to standby with hot_standby=off |
Previous Message | Konstantin Knizhnik | 2020-04-03 13:34:17 | Re: zombie connections |