brooklyn-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rich...@apache.org
Subject [12/25] git commit: Tidy persistence TODO comments
Date Sun, 01 Jun 2014 20:15:27 GMT
Tidy persistence TODO comments


Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/8829801e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/8829801e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/8829801e

Branch: refs/heads/master
Commit: 8829801ed2b9399dda4a4565eecd44167d3b273b
Parents: 50c0f69
Author: Aled Sage <aled.sage@gmail.com>
Authored: Tue May 27 10:51:13 2014 +0100
Committer: Aled Sage <aled.sage@gmail.com>
Committed: Fri May 30 10:24:38 2014 +0100

----------------------------------------------------------------------
 .../java/brooklyn/management/internal/EntityChangeListener.java | 4 +++-
 .../brooklyn/management/internal/EntityManagementSupport.java   | 5 +++--
 2 files changed, 6 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/8829801e/core/src/main/java/brooklyn/management/internal/EntityChangeListener.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/brooklyn/management/internal/EntityChangeListener.java b/core/src/main/java/brooklyn/management/internal/EntityChangeListener.java
index 36a6324..d564074 100644
--- a/core/src/main/java/brooklyn/management/internal/EntityChangeListener.java
+++ b/core/src/main/java/brooklyn/management/internal/EntityChangeListener.java
@@ -30,7 +30,9 @@ public interface EntityChangeListener {
 
     void onChildrenChanged();
 
-    void onPoliciesChanged(); // TODO
+    // FIXME Also want something to be notified when policy's state/config changes.
+    //       Do we want a separate PolicyChangeListener instead? Or everything through EntityChangeListener?
+    void onPoliciesChanged();
 
     void onEffectorStarting(Effector<?> effector);
     

http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/8829801e/core/src/main/java/brooklyn/management/internal/EntityManagementSupport.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/brooklyn/management/internal/EntityManagementSupport.java
b/core/src/main/java/brooklyn/management/internal/EntityManagementSupport.java
index 6d65648..6b9dcde 100644
--- a/core/src/main/java/brooklyn/management/internal/EntityManagementSupport.java
+++ b/core/src/main/java/brooklyn/management/internal/EntityManagementSupport.java
@@ -344,9 +344,10 @@ public class EntityManagementSupport {
         }
         @Override
         public void onAttributeChanged(AttributeSensor<?> attribute) {
-            // if important persist, otherwiise ignore
+            // TODO Could make this more efficient by inspecting the attribute to decide
if needs persisted
+            // immediately, or not important, or transient (e.g. do we really need to persist

+            // request-per-second count for rebind purposes?!)
             getManagementContext().getRebindManager().getChangeListener().onChanged(entity);
-            // getManagementContext().getRebindManager().getAttributeChangeListener().onChanged(entity,
attribute);
         }
         @Override
         public void onConfigChanged(ConfigKey<?> key) {


Mime
View raw message