qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jim Meyering <...@meyering.net>
Subject Re: FYI, bdbstore: Instrument all tests so that they are run via valgrind
Date Wed, 17 Jan 2007 21:45:57 GMT
Alan Conway <aconway@redhat.com> wrote:
> On Tue, 2007-01-16 at 11:29 -0500, Alan Conway wrote:
>> Waiting for startup is a classic problem, we need a good general
>> solution. How about
>> qpidd --waitforbroker <timeout>
>>   Attempt to contact the broker for up to <timeout> seconds. Exit status
>> 0 if the broker was contacted, 1 if the timeout expired.
>
> A better solution: have qpidd --daemon itself wait until it has started
> successfully! We could create a shared semaphore or somesuch before we
> fork the daemon, and have the daemon process signal when it has
> successfully called accept(). That way you can always safely start a
> client immediately after starting qpidd --daemon.

I prefer the former, since it would be useful not just at start-up --
e.g., also to test whether a broker (or something) is listening on the
specified port at any later time.

Mime
View raw message