stratos-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From im...@apache.org
Subject stratos git commit: Fixing mock member termination logic
Date Tue, 09 Dec 2014 09:42:39 GMT
Repository: stratos
Updated Branches:
  refs/heads/4.1.0-test 106822c25 -> ca93b9da3


Fixing mock member termination logic


Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/ca93b9da
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/ca93b9da
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/ca93b9da

Branch: refs/heads/4.1.0-test
Commit: ca93b9da3bf458d9dce4f7571c10f73e18be81e4
Parents: 106822c
Author: Imesh Gunaratne <imesh@apache.org>
Authored: Tue Dec 9 15:12:01 2014 +0530
Committer: Imesh Gunaratne <imesh@apache.org>
Committed: Tue Dec 9 15:12:33 2014 +0530

----------------------------------------------------------------------
 .../stratos/cloud/controller/iaases/mock/MockMember.java  | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/ca93b9da/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/mock/MockMember.java
----------------------------------------------------------------------
diff --git a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/mock/MockMember.java
b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/mock/MockMember.java
index 6e4a83b..65a5cb2 100644
--- a/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/mock/MockMember.java
+++ b/components/org.apache.stratos.cloud.controller/src/main/java/org/apache/stratos/cloud/controller/iaases/mock/MockMember.java
@@ -72,6 +72,10 @@ public class MockMember implements Runnable, Serializable {
         while (!terminated) {
             sleep(1000);
         }
+
+        if (log.isInfoEnabled()) {
+            log.info(String.format("Mock member terminated: [member-id] %s", mockMemberContext.getMemberId()));
+        }
     }
 
     private void startInstanceNotifierReceiver() {
@@ -145,12 +149,6 @@ public class MockMember implements Runnable, Serializable {
     }
 
     public void terminate() {
-        String memberId = mockMemberContext.getMemberId();
         terminated = true;
-        scheduler.shutdownNow();
-
-        if (log.isInfoEnabled()) {
-            log.info(String.format("Mock member terminated: [member-id] %s", memberId));
-        }
     }
 }


Mime
View raw message