From: | Vivek Khera <khera(at)kcilink(dot)com> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | best way to implement producer/consumer in Perl |
Date: | 2001-05-02 14:47:50 |
Message-ID: | x71yq7kdt5.fsf@onceler.kciLink.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
I've got an application that creates work and posts the work requests
to a table. Each work request is just a single row in the table.
I've also got two systems that do the work based on the requests in
the table.
It seems that ideally, I could use the LISTEN/NOTIFY features to tell
the consumers when there is work. However, what I really need is a
blocking LISTEN. That is, it just sits there until it gets a NOTIFY.
Right now, the consumer checks for work every so often, and most of
the time finds none.
What's the best way to implement such a thing in Perl? Is there a
blocking LISTEN?
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Vivek Khera, Ph.D. Khera Communications, Inc.
Internet: khera(at)kciLink(dot)com Rockville, MD +1-240-453-8497
AIM: vivekkhera Y!: vivek_khera http://www.khera.org/~vivek/
From | Date | Subject | |
---|---|---|---|
Next Message | Jeff Eckermann | 2001-05-02 14:48:43 | RE: Improve a query... |
Previous Message | Bruce Momjian | 2001-05-02 14:45:09 | Re: disk usage advice needed |