Re: Add memory_limit_hits to pg_stat_replication_slots
| От | Bertrand Drouvot |
|---|---|
| Тема | Re: Add memory_limit_hits to pg_stat_replication_slots |
| Дата | |
| Msg-id | aNEEqgDWxVeCZc6s@ip-10-97-1-34.eu-west-3.compute.internal обсуждение исходный текст |
| Ответ на | Re: Add memory_limit_hits to pg_stat_replication_slots (Masahiko Sawada <sawada.mshk@gmail.com>) |
| Ответы |
Re: Add memory_limit_hits to pg_stat_replication_slots
|
| Список | pgsql-hackers |
Hi, On Thu, Sep 11, 2025 at 03:24:54PM -0700, Masahiko Sawada wrote: > On Wed, Aug 27, 2025 at 12:26 AM Bertrand Drouvot > <bertranddrouvot.pg@gmail.com> wrote: > > > > Looking forward to your feedback, > > Yes, Thanks for looking at it! > it's a quite different situation in two cases: spilling 100 > transactions in one ReorderBufferCheckMemoryLimit() call and spilling > 1 transaction in each 100 ReorderBufferCheckMemoryLimit() calls, even > though spill_txn is 100 in both cases. And we don't have any > statistics to distinguish between these cases. Right. > One minor comment is: > > @@ -1977,6 +1978,7 @@ UpdateDecodingStats(LogicalDecodingContext *ctx) > repSlotStat.stream_bytes = rb->streamBytes; > repSlotStat.total_txns = rb->totalTxns; > repSlotStat.total_bytes = rb->totalBytes; > + repSlotStat.memory_limit_hits = rb->memory_limit_hits; > > Since other statistics counter names are camel cases I think it's > better to follow that for the new counter. Makes sense, done with memoryLimitHits in v2 attached (that's the only change as compared with v1). Regards, -- Bertrand Drouvot PostgreSQL Contributors Team RDS Open Source Databases Amazon Web Services: https://aws.amazon.com
Вложения
В списке pgsql-hackers по дате отправления: