couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Davis <paul.joseph.da...@gmail.com>
Subject Re: [os_daemons] & couchdb-lucene process
Date Sun, 02 Sep 2012 21:00:32 GMT
couchdb-lucene probably doesn't listen to its stdio file descriptors
to know when to shut down (or alternatively, monitor its parent
process ID).

On Sun, Sep 2, 2012 at 2:57 PM, muji <freeformsystems@gmail.com> wrote:
> I've just started the process of integrating couchdb-lucene with my
> project and thought that the lucene server would be a good candidate
> for integrating using the [os_daemons] functionality.
>
> My configuration looks like:
>
> [os_daemons]
> couchdb_lucene = /usr/local/divebox/sbin/couchdb-lucene/bin/run -with
>
> couch dutifully starts the process upon start up and monitors the
> process while it is running but when I shut couch down the
> couchdb-lucene java process is still running.
>
> Is this expected behaviour?
>
> This behaviour of course leaves rogue java processes running after
> couch server restarts (the new processes as they cannot bind to the
> lucene server port). It is arguable that the couchdb-lucene program
> should quit with a non-zero exit status when the server port is
> already in use, but then the question is whether couchdb would
> continue to monitor the os_daemon process started previously? I guess
> not as couch would not attempt to start a new process if it detected
> the one from a previously running couch.
>
> Personally, I think the [os_daemons] functionality should also
> terminate the process at shutdown, but then I guess this would need to
> be optional for use cases where the daemon is persistent when couch is
> shutdown but couch is still used to monitor the process while it is
> up.
>
> Any thoughts/advice much appreciated.
>
> --
> mischa (aka muji).

Mime
View raw message