From: | Hans-Jürgen Schönig <postgres(at)cybertec(dot)at> |
---|---|
To: | pgsql-patches(at)postgresql(dot)org |
Subject: | NO WAIT ... |
Date: | 2004-02-18 17:14:15 |
Message-ID: | 40339D67.90208@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
hi everyone ...
i have attached a patch implementing NO WAIT with the help of a GUC
variable.
documentation should be included as well.
it works nicely for me.
test=# begin;
BEGIN
test=# show wait_for_locks;
wait_for_locks
----------------
row share
(1 row)
test=# lock table x in exclusive mode;
LOCK TABLE
test=# commit;
COMMIT
test=# begin;
BEGIN
test=# -- somebody else has locked the table ...
test=# lock table x in exclusive mode;
ERROR: LockAcquire failed
[hs(at)fedora pgsql]$ difforig > nowait.patch
./doc/src/sgml/runtime.sgml
./src/backend/storage/lmgr/lock.c
./src/backend/utils/misc/guc.c
./src/backend/utils/misc/postgresql.conf.sample
./src/bin/psql/tab-complete.c
./src/include/storage/lock.h
./src/include/utils/guc.h
i hope this patch is ok.
if there are any modifications needed just drop me a line.
maybe i will have some spare time to implement "SELECT FOR UPDATE
NOWAIT" (SQL version). maybe this extension would make sense as well
because many people porting from oracle to pg would like that.
cheers,
Hans
--
Cybertec Geschwinde u Schoenig
Schoengrabern 134, A-2020 Hollabrunn, Austria
Tel: +43/2952/30706 or +43/664/233 90 75
www.cybertec.at, www.postgresql.at, kernel.cybertec.at
Attachment | Content-Type | Size |
---|---|---|
nowait.patch | text/plain | 7.7 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2004-02-18 17:27:29 | Re: [SQL] 7.4 - FK constraint performance |
Previous Message | Tom Lane | 2004-02-18 16:29:21 | Re: OIDs, CTIDs, updateable cursors and friends |
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2004-02-18 17:33:59 | Re: Doing psql's lexing with flex |
Previous Message | Tom Lane | 2004-02-18 16:32:54 | Re: Doing psql's lexing with flex |