Re: explain format json, unit for serialize and memory are different.

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: explain format json, unit for serialize and memory are different.
Дата
Msg-id ZkL5G7UmMMwbyyVl@paquier.xyz
обсуждение исходный текст
Ответ на Re: explain format json, unit for serialize and memory are different.  (Daniel Gustafsson <daniel@yesql.se>)
Ответы Re: explain format json, unit for serialize and memory are different.  (David Rowley <dgrowleyml@gmail.com>)
Список pgsql-hackers
On Mon, May 13, 2024 at 11:22:08AM +0200, Daniel Gustafsson wrote:
> Since json (and yaml/xml) is intended to be machine-readable I think we use a
> single unit for all values, and document this fact.

Agreed with the documentation gap.  Another thing that could be worth
considering is to add the units aside with the numerical values, say:
"Memory Used": {"value": 23432, "units": "bytes"}

That would require changing ExplainProperty() so as the units are
showed in some shape, while still being readable when parsed.  I
wouldn't recommend doing that in v17, but perhaps v18 could do better?

Units are also ignored for the XML and yaml outputs.
--
Michael

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: jian he
Дата:
Сообщение: Re: SQL:2011 application time
Следующее
От: jian he
Дата:
Сообщение: Bibliography section, some references cannot be found