helix-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s..@apache.org
Subject git commit: [HELIX-7] fix intermittent failures
Date Wed, 20 Feb 2013 18:33:30 GMT
Updated Branches:
  refs/heads/master 0c01bbbdb -> 7d4546720


[HELIX-7] fix intermittent failures

Project: http://git-wip-us.apache.org/repos/asf/incubator-helix/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-helix/commit/7d454672
Tree: http://git-wip-us.apache.org/repos/asf/incubator-helix/tree/7d454672
Diff: http://git-wip-us.apache.org/repos/asf/incubator-helix/diff/7d454672

Branch: refs/heads/master
Commit: 7d454672062b7652704daeafb5dac4bbeb50dd14
Parents: 0c01bbb
Author: slu2011 <lushi04@gmail.com>
Authored: Wed Feb 20 10:33:20 2013 -0800
Committer: slu2011 <lushi04@gmail.com>
Committed: Wed Feb 20 10:33:20 2013 -0800

----------------------------------------------------------------------
 .../helix/integration/TestSchedulerMessage.java    |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-helix/blob/7d454672/helix-core/src/test/java/org/apache/helix/integration/TestSchedulerMessage.java
----------------------------------------------------------------------
diff --git a/helix-core/src/test/java/org/apache/helix/integration/TestSchedulerMessage.java
b/helix-core/src/test/java/org/apache/helix/integration/TestSchedulerMessage.java
index aaa7959..23ce790 100644
--- a/helix-core/src/test/java/org/apache/helix/integration/TestSchedulerMessage.java
+++ b/helix-core/src/test/java/org/apache/helix/integration/TestSchedulerMessage.java
@@ -519,6 +519,13 @@ public class TestSchedulerMessage extends ZkStandAloneCMTestBaseWithPropertyServ
     Assert.assertEquals(0, factory._results.size());
     PropertyKey controllerTaskStatus = keyBuilder.controllerTaskStatus(
         MessageType.SCHEDULER_MSG.toString(), schedulerMessage.getMsgId());
+    for(int i = 0; i< 10; i++)
+    {
+      if(helixDataAccessor.getProperty(controllerTaskStatus) == null)
+      {
+        Thread.sleep(1000);
+      }
+    }
     ZNRecord statusUpdate = helixDataAccessor.getProperty(controllerTaskStatus)
         .getRecord();
     Assert.assertTrue(statusUpdate.getMapField("SentMessageCount")


Mime
View raw message