You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2017/10/06 08:06:29 UTC

[05/23] brooklyn-server git commit: fix visibility: entity init runs in same thread

fix visibility: entity init runs in same thread


Project: http://git-wip-us.apache.org/repos/asf/brooklyn-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/brooklyn-server/commit/84d24d1a
Tree: http://git-wip-us.apache.org/repos/asf/brooklyn-server/tree/84d24d1a
Diff: http://git-wip-us.apache.org/repos/asf/brooklyn-server/diff/84d24d1a

Branch: refs/heads/master
Commit: 84d24d1a949275e6bad3bbabefe6bf422f9fade7
Parents: d4c9fe1
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Tue Sep 19 13:09:39 2017 +0100
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Tue Sep 19 13:12:11 2017 +0100

----------------------------------------------------------------------
 .../apache/brooklyn/core/objs/proxy/InternalEntityFactory.java   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/84d24d1a/core/src/main/java/org/apache/brooklyn/core/objs/proxy/InternalEntityFactory.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/brooklyn/core/objs/proxy/InternalEntityFactory.java b/core/src/main/java/org/apache/brooklyn/core/objs/proxy/InternalEntityFactory.java
index a14225b..bd6cc1d 100644
--- a/core/src/main/java/org/apache/brooklyn/core/objs/proxy/InternalEntityFactory.java
+++ b/core/src/main/java/org/apache/brooklyn/core/objs/proxy/InternalEntityFactory.java
@@ -309,7 +309,7 @@ public class InternalEntityFactory extends InternalFactory {
          * which currently show up at the top level once the initializer task completes.
          * TODO It would be nice if these schedule tasks were grouped in a bucket! 
          */
-        ((EntityInternal)entity).getExecutionContext().submit(Tasks.builder().dynamic(false).displayName("Entity initialization")
+        ((EntityInternal)entity).getExecutionContext().get(Tasks.builder().dynamic(false).displayName("Entity initialization")
                 .tag(BrooklynTaskTags.TRANSIENT_TASK_TAG)
                 .body(new Runnable() {
             @Override
@@ -354,7 +354,7 @@ public class InternalEntityFactory extends InternalFactory {
                     initEntityAndDescendants(child.getId(), entitiesByEntityId, specsByEntityId);
                 }
             }
-        }).build()).getUnchecked();
+        }).build());
     }
     
     /**