Re: Configurable FP_LOCK_SLOTS_PER_BACKEND
От | Matt Smiley |
---|---|
Тема | Re: Configurable FP_LOCK_SLOTS_PER_BACKEND |
Дата | |
Msg-id | CA+eRB3oQeQAa3mO5kAQ59+jza7_XMOC28dbsy-aauO0Y7YuiWg@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Configurable FP_LOCK_SLOTS_PER_BACKEND (Tomas Vondra <tomas.vondra@enterprisedb.com>) |
Список | pgsql-hackers |
Why would the access frequency be uniform? In particular, there's a huge
variability in how long the locks need to exist
As a supporting data point, our example production workload shows a 3x difference between the most versus least frequently contended lock_manager lock:
Since we deterministically distribute relations among those 16 lock_manager lwlocks by hashing their lock tag, we can probably assume a roughly uniform number of relations are being managed by each lock_manager lock, but the demand (and contention) for them is non-uniform. This 3x spread corroborates the intuition that some relations are locked more frequently than others (that being both a schema- and workload-specific property).
Since we're contemplating a new hashing scheme, I wonder how we could accommodate that kind of asymmetry, where some relations are locked more frequently than others.
В списке pgsql-hackers по дате отправления: