Aled Sage created BROOKLYN-145:
----------------------------------

             Summary: SameServerEntity reported incorrectly (temporary) "up" 
before children started
                 Key: BROOKLYN-145
                 URL: https://issues.apache.org/jira/browse/BROOKLYN-145
             Project: Brooklyn
          Issue Type: Bug
    Affects Versions: 0.7.0-SNAPSHOT
            Reporter: Aled Sage


The ComputeServiceIndicatorsFromChildrenAndMembers.UP_QUORUM_CHECK behaviour 
recently changed: it has default atLeastOneUnlessEmpty, and filters out those 
children/members that have not yet started.

The consequence for SameServerEntity is that it incorrectly reports "up" 
temporarily at the beginning of startup. When its children were in expected 
states (i.e. none were on-fire, and all were still off because start() had not 
been called on them), then the SameServerEntity reported "up". This was because 
all non-started children where filtered out, so the quorum check treated it as 
"empty" (i.e. no children/members).

A customer is using a SameServerEntity to start two processes, and has another 
entity configured with an INSTALL_LATCH to block until the SameServerEntity is 
up. The temporary "up" was enough to unblock the latch, causing the other 
entity to continue prematurely.

I suggest we change the default in SameServerEntity. For example:

    {noformat}
    @Override
    protected void initEnrichers() {
        super.initEnrichers();
        addEnricher(ServiceStateLogic.newEnricherFromChildren()
                
.configure(ComputeServiceIndicatorsFromChildrenAndMembers.UP_QUORUM_CHECK, 
QuorumCheck.QuorumChecks.allAndAtLeastOne()));
    }
    {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to