Re: Lock timeout detection in postgres 7.3.1
От | Bruce Momjian |
---|---|
Тема | Re: Lock timeout detection in postgres 7.3.1 |
Дата | |
Msg-id | 200302120300.h1C30t224373@candle.pha.pa.us обсуждение исходный текст |
Ответ на | Re: Lock timeout detection in postgres 7.3.1 (Tomasz Myrta <jasiek@klaster.net>) |
Список | pgsql-sql |
Tomasz Myrta wrote: > Christoph Haller wrote: > <cut> > > Yupp, I agree. > > But from former DBMS I was dealing with, > > I know this SET TIMEOUT called feature, which if properly set > > terminated processes like that hanging on T2. > > Is there something comparable within Postgres? > > PostgreSQL 7.3 Documentation > 3.4. Run-time Configuration > STATEMENT_TIMEOUT (integer) > Aborts any statement that takes over the specified number of milliseconds. A value of zero turns off the timer. > DEADLOCK_TIMEOUT (integer) > This is the amount of time, in milliseconds, to wait on a lock before checking to see if there is a deadlock condition > > > In this case I suppose 2 things: > - table has a lot of records and you should just wait to finish operation. > - another query locked the table and it is realy a deadlock One of the uses of STATEMENT_TIMEOUT is to allow a LOCK or query to fail if it doesn't complete in a short time. We don't have a special timer to say if we are waiting on a lock for a specified time --- just a query-level timer. -- Bruce Momjian | http://candle.pha.pa.us pgman@candle.pha.pa.us | (610) 359-1001+ If your life is a hard drive, | 13 Roberts Road + Christ can be your backup. | Newtown Square, Pennsylvania19073
В списке pgsql-sql по дате отправления: