commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian Emmons <>
Subject Re: [daemon] jsvc won't recognize my entry point class
Date Thu, 07 Mar 2013 13:42:12 GMT

On Mar 5, 2013, at 11:36 AM, Mladen Turk <> wrote:
> On 03/04/2013 06:00 PM, Ian Emmons wrote:
>> Update:  I've done some digging in the jsvc source code, and it appears to be at
odds with the documentation [1].  The docs indicate that I can (a) write a Java class that
implements the Daemon interface, or (b) define a class that implements four specific methods
(init, start, stop, destroy, with specific signatures).
>> If I choose (a), the docs say I needs to put the commons-daemon jar on my classpath
(an obvious requirement), but if I choose (b), then the jar is not needed.  However, the jsvc
source code seems to load the DaemonLoader class in both cases, and so therefore the jar is
always required.
>> Can a someone familiar with the jsvc internals confirm this analysis?  If I am correct,
then I will enter a JIRA issue against the docs.
> Yes, commons-daemon is always required.  If you do not specify Daemon interface, it's
still created internally and calls your methods.  I don't see anything that says that its
not required. It's your presumption, so perhaps a statement that its always needed would be
more clear.  You are welcome to write something and if it make sense, I'll commit it.

The part of the docs I'm referring to is [1], where it shows two examples of invoking jsvc,
one corresponding to case (a) and the other to case (b).  The only difference between the
two is that the example for case (b) omits the commons-daemon jar from the class path.  The
change I would suggest it to make the second example identical to the first.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message