Distinguishing autovacuum activity in pg_stat_activity
I was just noticing that $SUBJECT is hard --- the entry in current_query
looks exactly like a manual vacuum command, and there's not anything in
the other fields that looks different either.
Since autovacuum.c is making up its pgstat_report_activity string
anyway, it would be easy to make the string look like, say,
AUTO VACUUM ANALYZE foo.bar
I think this would be a helpful change, but some might find it
confusing. Thoughts?
regards, tom lane
On Jan 13, 2008 10:59 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
I think this would be a helpful change, but some might find it
confusing. Thoughts?
If possible, something like:
autovacuum: VACUUM ANALYZE foo.bar
could be less confusing.
It's weird to just add AUTO in front of the query.
--
Guillaume
Tom Lane wrote:
I was just noticing that $SUBJECT is hard --- the entry in current_query
looks exactly like a manual vacuum command, and there's not anything in
the other fields that looks different either.Since autovacuum.c is making up its pgstat_report_activity string
anyway, it would be easy to make the string look like, say,
AUTO VACUUM ANALYZE foo.barI think this would be a helpful change, but some might find it
confusing. Thoughts?
I find
AUTOVACUUM ANALYZE foo.bar more clear.
Joshua D. Drake
Show quoted text
regards, tom lane
---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?
On Jan 13, 2008 11:27 PM, Joshua D. Drake <jd@commandprompt.com> wrote:
AUTOVACUUM ANALYZE foo.bar more clear.
Doesn't autovacuum also trigger ANALYZE only?
That's why I proposed an 'autovacuum:' prefix.
--
Guillaume
Guillaume Smet wrote:
On Jan 13, 2008 11:27 PM, Joshua D. Drake <jd@commandprompt.com> wrote:
AUTOVACUUM ANALYZE foo.bar more clear.
Doesn't autovacuum also trigger ANALYZE only?
That's why I proposed an 'autovacuum:' prefix.
Oh so:
autovacuum: vacuum
autovacuum: analyze
autovacuum: vacuum analyze
Yeah that's cool.
Joshua D. Drake
Show quoted text
--
Guillaume
Guillaume Smet escribi�:
On Jan 13, 2008 10:59 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
I think this would be a helpful change, but some might find it
confusing. Thoughts?If possible, something like:
autovacuum: VACUUM ANALYZE foo.bar
could be less confusing.
It's weird to just add AUTO in front of the query.
Whether the string is "AUTO " or "autovacuum: " seems rather the same
thing to me :-) I agree with the general idea. I think "autovacuum: "
makes it clearer that it's not part of the actual command syntax, so
maybe I'll put half a vote for that option.
--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.
On Jan 14, 2008 1:31 AM, Alvaro Herrera <alvherre@commandprompt.com> wrote:
Whether the string is "AUTO " or "autovacuum: " seems rather the same
thing to me :-) I agree with the general idea.
Yeah, forgot to mention I find it a very good idea.
--
Guillaume
Alvaro Herrera <alvherre@commandprompt.com> writes:
Whether the string is "AUTO " or "autovacuum: " seems rather the same
thing to me :-) I agree with the general idea. I think "autovacuum: "
makes it clearer that it's not part of the actual command syntax, so
maybe I'll put half a vote for that option.
Okay by me. Do you want to make the change?
regards, tom lane
Tom Lane escribi�:
Alvaro Herrera <alvherre@commandprompt.com> writes:
Whether the string is "AUTO " or "autovacuum: " seems rather the same
thing to me :-) I agree with the general idea. I think "autovacuum: "
makes it clearer that it's not part of the actual command syntax, so
maybe I'll put half a vote for that option.Okay by me. Do you want to make the change?
Will do (early tomorrow)
--
Alvaro Herrera http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.