Hi, On 2022-02-25 14:25:52 +0800, Julien Rouhaud wrote: > > Basically the type of stats we're trying to move to dynamic shared memory is > > about counters that should persist for a while and are accumulated across > > connections etc. Whereas backend_status.c is more about tracking the current > > state (what query is a backend running, what user, etc). > > But would it be acceptable to use dynamic shared memory in backend_status and > e.g. have a dsa_pointer rather than a fixed length array?
Might be OK, but it does add a fair bit of complexity. Suddenly there's a bunch more initialization order dependencies that you don't have right now. I'd not go there for just this. Greetings, Andres Freund