Re: using database for queuing operations?
От | Jim C. Nasby |
---|---|
Тема | Re: using database for queuing operations? |
Дата | |
Msg-id | 20040922181954.GU1297@decibel.org обсуждение исходный текст |
Ответ на | Re: using database for queuing operations? (John Sidney-Woollett <johnsw@wardbrook.com>) |
Ответы |
Re: using database for queuing operations?
|
Список | pgsql-general |
Ahh, yes, forgot about that. Very handy to have. But even without that you wouldn't have a race condition, just a blocked process, right? On Tue, Sep 21, 2004 at 07:15:08AM +0100, John Sidney-Woollett wrote: > Oracle also has the NOWAIT option for use with the SELECT ... FOR UPDATE > query. If the record is locked, the NOWAIT causes the query to generate > an exception (rather than blocking) which can then be caught and handled > - it helps prevent race conditions. A very nice feature! > > John Sidney-Woollett > > Jim C. Nasby wrote: > >What's the race in the SELECT FOR UPDATE? > > > >BTW, this is one nice thing about Oracle... it comes with a built-in > >queuing mechanism. It would probably be worth trying to write a generic > >queuing system and stick it in Gborg. > > > >Incidentally, Oracle also supports user-named locks, which would > >probably make this easier to do. LOCK TABLE works, but it's more brute > >force than is needed. Unfortunately, I don't see a way to simply add > >such a thing onto PostgreSQL without adding it to the core. > > ---------------------------(end of broadcast)--------------------------- > TIP 3: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly > -- Jim C. Nasby, Database Consultant decibel@decibel.org Give your computer some brain candy! www.distributed.net Team #1828 Windows: "Where do you want to go today?" Linux: "Where do you want to go tomorrow?" FreeBSD: "Are you guys coming, or what?"
В списке pgsql-general по дате отправления: