brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Aled Sage (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (BROOKLYN-268) DynamicClusterTest.testServiceUpAfterStartingWithNoMembers failing
Date Fri, 20 May 2016 11:06:12 GMT

     [ https://issues.apache.org/jira/browse/BROOKLYN-268?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Aled Sage resolved BROOKLYN-268.
--------------------------------
       Resolution: Fixed
    Fix Version/s: 0.10.0

> DynamicClusterTest.testServiceUpAfterStartingWithNoMembers failing
> ------------------------------------------------------------------
>
>                 Key: BROOKLYN-268
>                 URL: https://issues.apache.org/jira/browse/BROOKLYN-268
>             Project: Brooklyn
>          Issue Type: Bug
>            Reporter: Aled Sage
>            Priority: Minor
>             Fix For: 0.10.0
>
>
> The test {{DynamicClusterTest.testServiceUpAfterStartingWithNoMembers}} is failing for
me locally with 0.10.0-SNAPSHOT (exception below).
> {noformat}
> FAILED: testServiceUpAfterStartingWithNoMembers
> org.apache.brooklyn.util.exceptions.PropagatedRuntimeException: failed succeeds-eventually,
69 attempts, 30003ms elapsed: AssertionError: entity=DynamicClusterImpl{id=odZv4xRV}; attribute=Sensor:
service.state (org.apache.brooklyn.core.entity.lifecycle.Lifecycle) expected [running] but
found [on-fire]
> 	at org.apache.brooklyn.util.exceptions.Exceptions.propagate(Exceptions.java:164)
> 	at org.apache.brooklyn.util.exceptions.Exceptions.propagateAnnotated(Exceptions.java:144)
> 	at org.apache.brooklyn.test.Asserts.succeedsEventually(Asserts.java:963)
> 	at org.apache.brooklyn.test.Asserts.succeedsEventually(Asserts.java:854)
> 	at org.apache.brooklyn.core.entity.EntityAsserts.assertAttributeEqualsEventually(EntityAsserts.java:67)
> 	at org.apache.brooklyn.core.entity.EntityAsserts.assertAttributeEqualsEventually(EntityAsserts.java:62)
> 	at org.apache.brooklyn.entity.group.DynamicClusterTest.testServiceUpAfterStartingWithNoMembers(DynamicClusterTest.java:172)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:84)
> 	at org.testng.internal.Invoker.invokeMethod(Invoker.java:714)
> 	at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:901)
> 	at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1231)
> 	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:127)
> 	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:111)
> 	at org.testng.TestRunner.privateRun(TestRunner.java:767)
> 	at org.testng.TestRunner.run(TestRunner.java:617)
> 	at org.testng.SuiteRunner.runTest(SuiteRunner.java:348)
> 	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:343)
> 	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:305)
> 	at org.testng.SuiteRunner.run(SuiteRunner.java:254)
> 	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
> 	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
> 	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1224)
> 	at org.testng.TestNG.runSuitesLocally(TestNG.java:1149)
> 	at org.testng.TestNG.run(TestNG.java:1057)
> 	at org.testng.remote.RemoteTestNG.run(RemoteTestNG.java:115)
> 	at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:207)
> 	at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:178)
> Caused by: java.lang.AssertionError: entity=DynamicClusterImpl{id=odZv4xRV}; attribute=Sensor:
service.state (org.apache.brooklyn.core.entity.lifecycle.Lifecycle) expected [running] but
found [on-fire]
> 	at org.apache.brooklyn.test.Asserts.fail(Asserts.java:721)
> 	at org.apache.brooklyn.test.Asserts.failNotEquals(Asserts.java:114)
> 	at org.apache.brooklyn.test.Asserts.assertEquals(Asserts.java:436)
> 	at org.apache.brooklyn.core.entity.EntityAsserts.assertAttributeEquals(EntityAsserts.java:54)
> 	at org.apache.brooklyn.core.entity.EntityAsserts$1.run(EntityAsserts.java:70)
> 	at org.apache.brooklyn.test.Asserts$RunnableAdapter.call(Asserts.java:1277)
> 	at org.apache.brooklyn.test.Asserts.succeedsEventually(Asserts.java:930)
> 	... 28 more
> {noformat}
> Running the test with logging at trace, and searching for {{service.isUp}}, I see the
logging below:
> {noformat}
> 2016-05-17 15:14:03,135 TRACE o.a.b.c.entity.AbstractEntity [brooklyn-execmanager-RRpMDRbG-0]:
DynamicClusterImpl{id=UQli154h} setAttribute Sensor: service.isUp (java.lang.Boolean) true
> 2016-05-17 15:14:03,137 TRACE o.a.b.u.c.task.ValueResolver [brooklyn-execmanager-RRpMDRbG-0]:
ValueResolver[Object Sensor: service.isUp (java.lang.Boolean)] evaluated as Present[value=Sensor:
service.isUp (java.lang.Boolean)]
> 2016-05-17 15:14:03,138 TRACE o.a.b.u.c.task.ValueResolver [brooklyn-execmanager-RRpMDRbG-0]:
ValueResolver[Sensor Sensor: service.isUp (java.lang.Boolean)] evaluated as Present[value=Sensor:
service.isUp (java.lang.Boolean)]
> 2016-05-17 15:14:03,173 DEBUG o.a.b.c.m.i.LocalSubscriptionManager [main]: Creating subscription
iJMHeDc3 for DynamicClusterImpl{id=UQli154h} on DynamicClusterImpl{id=UQli154h} Sensor: service.isUp
(java.lang.Boolean) in SubscriptionContext(huqO8)
> 2016-05-17 15:14:03,174 DEBUG o.a.b.c.m.i.LocalSubscriptionManager [main]: Creating subscription
aSdTf34a for DynamicClusterImpl{id=UQli154h} on null Sensor: service.isUp (java.lang.Boolean)
in SubscriptionContext(huqO8)
> 2016-05-17 15:14:03,178 TRACE o.a.b.e.s.AbstractTransformer [brooklyn-execmanager-RRpMDRbG-2]:
Enricher Transformer{uniqueTag=service.isUp if no service.notUp.indicators, running=true,
entity=DynamicClusterImpl{id=UQli154h}, id=etHYCO6U} computed java.lang.Object@1a0a1852 from
DynamicClusterImpl{id=UQli154h}.Sensor: service.notUp.indicators (java.util.Map)=null @ 1463494443173
> 2016-05-17 15:14:03,178 TRACE o.a.b.c.entity.AbstractEntity [brooklyn-execmanager-RRpMDRbG-2]:
DynamicClusterImpl{id=UQli154h} removeAttribute Sensor: service.isUp (java.lang.Boolean)
> 2016-05-17 15:14:03,178 DEBUG o.a.b.core.sensor.AttributeMap [brooklyn-execmanager-RRpMDRbG-2]:
removing attribute service.isUp on DynamicClusterImpl{id=UQli154h}
> {noformat}
> In {{DynamicClusterImpl.initEnrichers}}, it has explicitly set service.isUp to true (and
also UP_QUORUM_CHECK to atLeastOneUnlessEmpty, and then registered this enricher). But because
the SERVICE_NOT_UP_INDICATORS is null another enricher clears the service.isUp value.
> Subsequently, when service.state.expected is set to "running", it computes that the cluster
is on-fire because service.isUp is still null.
> {noformat}
> 2016-05-17 15:14:03,595 WARN  o.a.b.c.e.l.ServiceStateLogic [brooklyn-execmanager-RRpMDRbG-6]:
Setting DynamicClusterImpl{id=UQli154h} on-fire due to problems when expected running, up=null,
not-up-indicators: null
> {noformat}



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

Mime
View raw message