Re: [PATCHES] Patch for UUID datatype (beta)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [PATCHES] Patch for UUID datatype (beta)
Дата
Msg-id 27536.1158590002@sss.pgh.pa.us
обсуждение исходный текст
Ответы Re: [PATCHES] Patch for UUID datatype (beta)  (Gevik Babakhani <pgdev@xs4all.nl>)
Re: [PATCHES] Patch for UUID datatype (beta)  (mark@mark.mielke.cc)
Список pgsql-hackers
Andreas Pflug <pgadmin@pse-consulting.de> writes:
> Isn't guaranteed uniqueness the very attribute that's expected? AFAIK
> there's a commonly accepted algorithm providing this.

Anyone who thinks UUIDs are guaranteed unique has been drinking too much
of the kool-aid.  They're at best probably unique.  Some generator
algorithms might make it more probable than others, but you simply
cannot "guarantee" it for UUIDs generated on noncommunicating machines.

One of the big reasons that I'm hesitant to put a UUID generation
function into core is the knowledge that none of them are or can be
perfect ... so people might need different ones depending on local
conditions.  I'm inclined to think that a reasonable setup would put
the datatype (with input, output, comparison and indexing support)
into core, but provide a generation function as a contrib module,
making it easily replaceable.

            regards, tom lane

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

Предыдущее
От: Martijn van Oosterhout
Дата:
Сообщение: Re: OID conflicts
Следующее
От: Gevik Babakhani
Дата:
Сообщение: Re: OID conflicts