Hello,
>TBH, I think that designing this as a hook-based solution is adding a whole lot of complexity for no value. The hard
partsof the problem are collecting the raw data and making the results visible to users, and both of those require
involvementof the core code. Where is the benefit from pushing some trivial >intermediate arithmetic into an external
module?
>If there's any at all, it's certainly not enough to justify problems such as you mention here.
>So I'd just create a "pgstat_report_percent_done()" type of interface in pgstat.c and then teach VACUUM to call it
directly.
Thank you for suggestion. I agree that adding code in core will reduce code complexity with no additional overhead.
Going by the consensus, I will update the patch with code to collect and store progress information from vacuum in
pgstat.cand
UI using pg_stat_activity view.
Thank you,
Rahila Syed
______________________________________________________________________
Disclaimer: This email and any attachments are sent in strictest confidence
for the sole use of the addressee and may contain legally privileged,
confidential, and proprietary data. If you are not the intended recipient,
please advise the sender by replying promptly to this email and then delete
and destroy this email and any attachments without any further use, copying
or forwarding.