Lazy xid assignment V3
От | Florian G. Pflug |
---|---|
Тема | Lazy xid assignment V3 |
Дата | |
Msg-id | 46DB6EDB.80608@phlo.org обсуждение исходный текст |
Ответы |
Re: Lazy xid assignment V3
Re: Lazy xid assignment V3 |
Список | pgsql-patches |
I tried sending this with the actual patch attached - this time, to pgsql-pacthes, but it seems that my mail didn't get through again. So it've put up the patch here: http://soc.phlo.org/lazyxidassign.v3.patch ---------------------------------------- Hi Here is an updated version of my patch. This is pretty much equivalent to the version V2, apart from the few minor things Tom criticized. The changes are. .) elog(ERROR) instead of Assert if there are to-be-deleted files, but no XID assigned on commit .) ResourceOwnerId is renamed to VirtualTransactionId. .) GetOldestXmin() checks GetTopTransactionIdIfAny() first, and only reverts to ReadNewTransactionId() if the former returns InvalidTransactionId. Since we didn't really reach an agreement on how xid_age should behave, I've reverted it back to the original version. So with this patch, xid_age will just force assignment of a xid. The other proposed ideas where .) Use some cached xid value which is kept stable for the duration of a transaction. .) Use RecentGlobalXmin. This makes the notion of xid age consistent with VACCUM. The value could change between statements though (for read-committed transactions). .) Use the current snaphot's xmax. This would be the closest possible approximation of using ReadNewTransasctionId() that keeps the xid age constant during a statement or transaction. (Depending on the xact being read-committed or serializable). greetings, Florian Pflug
В списке pgsql-patches по дате отправления: