Skip site navigation (1) Skip section navigation (2)

Re: Autovacuum launcher patch

From: Markus Schiltknecht <markus(at)bluegap(dot)ch>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: Autovacuum launcher patch
Date: 2007-01-29 19:58:25
Message-ID: 45BE51E1.1080600@bluegap.ch (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-patches
Alvaro Herrera wrote:
> Hmm, I remember eyeballing that code.  Would you mind sending me an URL
> to that file, or something?  Or maybe send me the files themselves?

Sure, here's a patch against current CVS. Please remove all the 
functions referencing to "buffer" and "buffer.h" to compile.

Remember that it's a work in progress thing. It has flaws. One issue 
that currently bugs me is, that processes can deadlock if they keep 
trying to create a message (IMessagesCreate), but fail because the queue 
is full of messages for themselves. A process should thus always try to 
fetch messages (via IMessagesCheck) and remove pending ones before 
retrying to send one. That's not always practical.

One design limitation is, that you have to know how large your message 
is as soon as you reserve (shared) memory for it, but that's intended.

At least I've stress tested the wrap-around code and it seems to work. 
No guarantees, though ;-)

Regards

Markus


Attachment: curr_imessages.patch
Description: text/x-diff (13.4 KB)

In response to

pgsql-hackers by date

Next:From: Henry B. HotzDate: 2007-01-29 20:44:51
Subject: Re: 10 weeks to feature freeze (Pending Work)
Previous:From: korrydDate: 2007-01-29 19:48:48
Subject: Re: shared_preload_libraries support on Win32?

pgsql-patches by date

Next:From: Bruce MomjianDate: 2007-01-29 20:21:55
Subject: Re: [ADMIN] server process (PID xxx) was
Previous:From: Alvaro HerreraDate: 2007-01-29 19:32:42
Subject: Re: [pgsql-patches] Autovacuum launcher patch

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group