On Tue, Mar 8, 2022 at 6:50 PM Andres Freund <andres@anarazel.de> wrote:
On 2022-03-08 15:55:04 -0700, David G. Johnston wrote: > On Tue, Mar 8, 2022 at 1:54 PM Andres Freund <andres@anarazel.de> wrote: > > One thing I'm not yet happy around the shared memory stats patch is > > naming. Currently a lot of comments say things like: > > > > * [...] We convert to > > * microseconds in PgStat_Counter format when transmitting to the > > collector. > >
"...format for writing to the statistics datastore"
> > or > > > > # - Query and Index Statistics Collector -
"...Statistics Collection"
> > > > or > > > > /* ---------- > > * pgstat_report_subscription_drop() - > > * > > * Tell the collector about dropping the subscription. > > * ---------- > > */
I would expect that either the function gets renamed or just goes away. Just changing the word "collector" isn't going to be a good change, the new description should describe whatever the new behavior is.
> > > > the immediate question for the patch is what to replace "collector" with. > > > > > Not really following the broader context here so this came out of nowhere > for me. What is the argument for changing the status quo here? Collector > seems like good term.
Sorry, probably should have shared a bit more context. The shared memory stats patch removes the stats collector process - which seems to make 'collector' not descriptive anymore...
As shown above I don't see that there is a single word that will simply replace "collector". We are changing a core design of the system and each dependent system will need to be tweaked in a context-appropriate manner.
As the process goes away we are now dealing directly with a conceptual datastore. And instead of referring to the implementation detail of how statistics are collected we can just refer to the "collection" behavior generically. Whether we funnel through a process or write directly to the datastore it is still statistics collection.