statement timeout test case

Started by Medi Montaseriover 23 years ago2 messagesgeneral
Jump to latest
#1Medi Montaseri
medi.montaseri@intransa.com

I'm trying to develop a test case to see how the statement_timeout in
7.3 works...

Can I just say...

make the change in $PGDATA/postgresql.conf, pg_ctl reload

In psql(1) session one say 'lock table test in EXCLUSIVE mode'
In psql(1) session two say 'select * from test'

What I'm expecting is that sessoion two should block and then timeout....

Thanks

PS: I don't see any unlock commands....does it automagically unlock the
table
when psql(1) session is closed.

#2Bruce Momjian
bruce@momjian.us
In reply to: Medi Montaseri (#1)
Re: statement timeout test case

Yep, it should work, though rememger that LOCK only locks for the
duration of the transaction.

---------------------------------------------------------------------------

Medi Montaseri wrote:

I'm trying to develop a test case to see how the statement_timeout in
7.3 works...

Can I just say...

make the change in $PGDATA/postgresql.conf, pg_ctl reload

In psql(1) session one say 'lock table test in EXCLUSIVE mode'
In psql(1) session two say 'select * from test'

What I'm expecting is that sessoion two should block and then timeout....

Thanks

PS: I don't see any unlock commands....does it automagically unlock the
table
when psql(1) session is closed.

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html

-- 
  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, Pennsylvania 19073