Re: Serializable Snapshot Isolation
От | Kevin Grittner |
---|---|
Тема | Re: Serializable Snapshot Isolation |
Дата | |
Msg-id | 4C9A07CA0200002500035B4C@gw.wicourts.gov обсуждение исходный текст |
Ответ на | Re: Serializable Snapshot Isolation (Kevin Grittner <grimkg@gmail.com>) |
Список | pgsql-hackers |
I wrote: > Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> wrote: > >> ISTM you never search the SerializableXactHash table using a hash >> key, except the one call in CheckForSerializableConflictOut, but >> there you already have a pointer to the SERIALIZABLEXACT struct. >> You only re-find it to make sure it hasn't gone away while you >> trade the shared lock for an exclusive one. If we find another >> way to ensure that, ISTM we don't need SerializableXactHash at >> all. >> it seems like it could be made simpler somehow.. > > After tossing it around in my head for a bit, the only thing that > I see (so far) which might work is to maintain a *list* of > SERIALIZABLEXACT objects in memory rather than a using a hash > table. The recheck after releasing the shared lock and acquiring > an exclusive lock would then go through SerializableXidHash. After discussion on a separate thread, I replaced that hash table with a home-grown shared memory list. I had to create a patch at that point due to the git migration, so I figured I might as well post it, too. There have been some non-trivial changes due to feedback on the prior posting. -Kevin
Вложения
В списке pgsql-hackers по дате отправления: