Re: machine-readable explain output

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Josh Berkus <josh(at)agliodbs(dot)com>
Subject: Re: machine-readable explain output
Date: 2009-06-13 13:08:44
Message-ID: 200906131608.45689.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Saturday 13 June 2009 01:10:06 Robert Haas wrote:
> <pgexplain>, as it happens... I could post some samples of the
> output, but it seems like it might be just as well to let those who
> are curious try it for themselves. I'd rather get opinions from
> people who care enough to download & test than from those who are just
> bikeshedding. :-)

I recommend, however, that you think about writing a regression test for this,
so the interfaces are explicit, and those tweaking them in the future know
what they are dealing with.

A couple of comments on the specifics of the output:

For the JSON format:

* Numbers should not be quoted.

For the XML format:

* Instead of <pgexplain>, use <explain> with an XML namespace declaration.

The schema name is missing in either output format. I think that was supposed
to be one of the features of this that the objects are unambiguously
qualified.

I'm not sure I like element names such as <Node-Type>, instead of say
<nodetype>, which is more like HTML and DocBook. (Your way might be more like
SOAP, I guess.)

Also, the result type of an EXPLAIN (format xml) should be type xml, not text.

In general, I like this direction very much. There will probably be more
tweaks on the output format over time. It's not like the plain EXPLAIN hasn't
been tweaked countless times.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2009-06-13 13:13:52 Re: pgindent run coming
Previous Message Stefan Kaltenbrunner 2009-06-13 10:14:29 char() overhead on read-only workloads not so insignifcant as the docs claim it is...