Re: "serializable" in comments and names

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: "serializable" in comments and names
Дата
Msg-id AANLkTimL4PgCQRXc3iP4FjGXOtGN1Bp_T3usmYUcrEV5@mail.gmail.com
обсуждение исходный текст
Ответ на Re: "serializable" in comments and names  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Ответы Re: "serializable" in comments and names  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Список pgsql-hackers
On Thu, Sep 2, 2010 at 11:41 AM, Kevin Grittner
<Kevin.Grittner@wicourts.gov> wrote:
>> How about IsXactIsoLevelSnapshot?  Just to be a bit shorter.
>
> I need two macros -- one which has the same definition as the
> current IsXactIsoLevelSerializable, to be used everywhere the old
> macro name currently is used, which conveys that it is an isolation
> level which is based on a transaction snapshot rather than statement
> snapshots (i.e., REPEATABLE READ or SERIALIZABLE) and a new macro
> (which I was planning to call IsXactIsoLevelFullySerializable) which
> conveys that it is the SERIALIZABLE isolation level.  Do you feel
> that IsXactIsoLevelSnapshot works with
> IsXactIsoLevelFullySerializable to convey the right semantics?  If
> not, what would you suggest?

OK, I see what you were going for.  The current definition is:

#define IsXactIsoLevelSerializable (XactIsoLevel >= XACT_REPEATABLE_READ)

...which is certainly a bit odd, since you'd think it would be
comparing against XACT_SERIALIZABLE given the name.

IsXactIsoLevelRepeatableRead()?

XactUsesPerXactSnapshot()?

Or, inverting the sense of it, XactUsesPerStatementSnapshot()?

Just brainstorming...

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company


В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Kevin Grittner"
Дата:
Сообщение: Re: installcheck-world failure
Следующее
От: "Kevin Grittner"
Дата:
Сообщение: Re: "serializable" in comments and names