> > No time this year.
> > If   necessary I will do it next year.
> > 
> > Thanks.
> 
> Yes.  I need to know if the code change between setitimer and select()
> causes the difference you are seeing.

OK, I have re-coded that section.  I had majorly broken it.

As part of the fix, I changed the deadlock detection in include/config.h
from 60 to 1.  Remember, config.h is generated from config.h.in.

Can you change it back to 60 to see that the timeout is working
properly?  The one-second default is not going to be noticable during
testing.


-- 
  Bruce Momjian                        |  http://www.op.net/~candle
  maillist@candle.pha.pa.us            |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

Tue, 29 Dec 1998 14:58:36 -0500 (EST)
Bruce Momjian <maillist@candle.pha.pa.us>
Re: [HACKERS] MVCC works in serialized mode!
> -----Original Message-----
> From: Bruce Momjian [mailto:maillist@candle.pha.pa.us]
> Sent: Wednesday, December 30, 1998 4:59 AM
> To: PostgreSQL-development
> Cc: Inoue@tpf.co.jp; vadim@krs.ru
> Subject: Re: [HACKERS] MVCC works in serialized mode!
> 
> 
> > > No time this year.
> > > If   necessary I will do it next year.
> > > 
> > > Thanks.
> > 
> > Yes.  I need to know if the code change between setitimer and select()
> > causes the difference you are seeing.
> 
> OK, I have re-coded that section.  I had majorly broken it.
> 
> As part of the fix, I changed the deadlock detection in include/config.h
> from 60 to 1.  Remember, config.h is generated from config.h.in.
> 
> Can you change it back to 60 to see that the timeout is working
> properly?  The one-second default is not going to be noticable during
> testing.
>

I changed DEADLOCK_CHECK_TIMER in config.h to 60 and compiled.
Deadlock check takes about 60 seconds.
So timeout is set to 60 properly.

And the result is as follows.

create table t1 (key int,a int);
insert into t1 values (1,1);

Session-1             Session-2

begin;                   begin;
BEGIN                  BEGIN
update t1 set a=1; 
UPDATE 1           
                            update t1 set a=1;
                            [ update is blocked ]
abort;
ABORT
		    [ immediately ]
                            UPDATE 1

It's OK.

Thanks a lot.

Hiroshi Inoue
Inoue@tpf.co.jp

Tue, 5 Jan 1999 18:48:53 +0900
"Hiroshi Inoue" <Inoue@tpf.co.jp>
RE: [HACKERS] MVCC works in serialized mode!