Re: our checks for read-only queries are not great

Tom Lane <[email protected]> Sun, 12 Jan 2020 12:06:06 -0500
Newsgroups gmane.comp.db.postgresql.devel.general
Message-ID <[email protected]>
Laurenz Albe <[email protected]> writes:
> Perhaps it would be good to consider this question:
> Do we call something "read-only" if it changes nothing, or do we call it
> "read-only" if it is allowed on a streaming replication standby?
> The first would be more correct, but the second may be more convenient.

Yeah, this is really the larger point at stake.  I'm not sure that
"read-only" and "allowed on standby" should be identical, nor even
that one should be an exact subset of the other.  They're certainly
by-and-large the same sets of operations, but there might be
exceptions that belong to only one set.  "read-only" is driven by
(some reading of) the SQL standard, while "allowed on standby" is
driven by implementation limitations, so I think it'd be dangerous
to commit ourselves to those being identical.

			regards, tom lane