Hi Ismael,

sfPing starts once the component is deployed and therefore it will check if the 
component is alive during sfDeploy and sfStart as well. This means that the 
components should not block on the sfDeploy and sfStart methods.

The general rule is that any long operation (ex. starting a DB) started inside 
those methods should be processed in a separate thread to avoid liveness 
failures.


To test if this is your case you can make liveness 0 (liveness = disabled)

  org.smartfrog.sfcore.processcompound.sfLivenessDelay=0

and see if your example now works.

If this solves your problem please file a bug against the Jetty component and 
we will fix it for next release.

Regards,

Julio Guijarro


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ismael Juma
Sent: 13 February 2008 01:08
To: [EMAIL PROTECTED]
Subject: [Smartfrog-support] Termination due to slow start-up.

Hi,

I've been experimenting with SmartFrog for deployment of Jetty in
multiple nodes. I have made good progress, but I found one issue that I
am unsure how to deal with.

Basically the web application is a bit slow to start causing it to be
terminated as soon as it finishes the start-up process. I added
"org.smartfrog.sfcore.processcompound.sfProcessTimeout=300" to
default.ini, but the problem still happens (even though start-up takes
less than that for sure). I can also confirm that if I disable the slow
operation (takes between 40 to 70 seconds), everything works as
expected.

After investigating a stacktrace[1] produced with tracing enabled, I
found that JettyToSFLifecycle#sfPing will cause a liveness failure if
the lifecycle is not yet running. Is it possible that a liveness test is
causing a failure because start-up has not finished even though the
sfProcessTimeout has not yet expired? If so, is this by design?

My expectation was that liveness tests could only cause a failure once
the component had started since there's a specific test (with different
time-out settings) for start-up. Did I misunderstand how it's supposed
to work? If so, I would appreciate suggestions on how to deal with this
case.

Thanks,
Ismael

[1] 2008/02/12 17:54:17:645 GMT [TRACE][LivenessSender_HOST
desktop.config:rootProcess:*unknown*] HOST
desktop.config:testProcess:testProcess - HOST
desktop.config:testProcess:testProcess
 Termination Record: HOST desktop.config:testProcess:testProcess:webApp,
type: abnormal,  description: Liveness Send Failure in HOST
desktop.config:testProcess:testProcess when calling HOST
desktop.config:testProcess:testProcess: webApp (Failure: Not started),
cause: SmartFrogLivenessException:: Not started, SmartFrog 3.12.018
(2008-01-21 12:47:17 GMT) <SmartFrogLivenessException:: Not started
    SmartFrog 3.12.018 (2008-01-21 12:47:17 GMT)>
        SmartFrogLivenessException:: Not started, SmartFrog 3.12.018
(2008-01-21 12:47:17 GMT)
        at
org.smartfrog.services.jetty.contexts.delegates.DelegateApplicationContext.ping(DelegateApplicationContext.java:149)
        at
org.smartfrog.services.www.context.ApplicationServerContextImpl.ping(ApplicationServerContextImpl.java:244)
        at
org.smartfrog.services.www.context.ApplicationServerContextImpl.sfPing(ApplicationServerContextImpl.java:213)
        at
org.smartfrog.sfcore.compound.CompoundImpl.sfPingChild(CompoundImpl.java:799)
        at
org.smartfrog.sfcore.compound.CompoundImpl.sfPingChildAndTerminateOnFailure(CompoundImpl.java:782)
        at
org.smartfrog.sfcore.compound.CompoundImpl.sfPingChildren(CompoundImpl.java:769)
        at
org.smartfrog.sfcore.compound.CompoundImpl.sfPing(CompoundImpl.java:755)
        at
org.smartfrog.sfcore.prim.LivenessSender.timerTick(LivenessSender.java:61)
        at org.smartfrog.sfcore.common.Timer.doTick(Timer.java:155)
        at org.smartfrog.sfcore.common.Timer.run(Timer.java:187)
        at java.lang.Thread.run(Thread.java:619)


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Smartfrog-support mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/smartfrog-support

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Smartfrog-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/smartfrog-users

Reply via email to