Repository: brooklyn-server
Updated Branches:
  refs/heads/master d407e5e52 -> 26e5fe2ad


Fix address publish bug


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

Branch: refs/heads/master
Commit: f3fa60050c83ee661d4f1d96dcf4298e481408d7
Parents: d407e5e
Author: Duncan Godwin <[email protected]>
Authored: Tue Apr 18 11:44:54 2017 +0100
Committer: Duncan Godwin <[email protected]>
Committed: Tue Apr 18 11:44:54 2017 +0100

----------------------------------------------------------------------
 .../location/jclouds/DefaultConnectivityResolver.java        | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/brooklyn-server/blob/f3fa6005/locations/jclouds/src/main/java/org/apache/brooklyn/location/jclouds/DefaultConnectivityResolver.java
----------------------------------------------------------------------
diff --git 
a/locations/jclouds/src/main/java/org/apache/brooklyn/location/jclouds/DefaultConnectivityResolver.java
 
b/locations/jclouds/src/main/java/org/apache/brooklyn/location/jclouds/DefaultConnectivityResolver.java
index c4f8fe8..29fe5a8 100644
--- 
a/locations/jclouds/src/main/java/org/apache/brooklyn/location/jclouds/DefaultConnectivityResolver.java
+++ 
b/locations/jclouds/src/main/java/org/apache/brooklyn/location/jclouds/DefaultConnectivityResolver.java
@@ -256,12 +256,8 @@ public class DefaultConnectivityResolver extends 
BasicConfigurableObject impleme
     }
 
     void publishNetworks(NodeMetadata node, Entity entity) {
-        if (entity.sensors().get(PRIVATE_ADDRESSES) == null) {
-            entity.sensors().set(PRIVATE_ADDRESSES, 
ImmutableSet.copyOf(node.getPrivateAddresses()));
-        }
-        if (entity.sensors().get(PUBLIC_ADDRESSES) == null) {
-            entity.sensors().set(PUBLIC_ADDRESSES, 
ImmutableSet.copyOf(node.getPublicAddresses()));
-        }
+        entity.sensors().set(PRIVATE_ADDRESSES, 
ImmutableSet.copyOf(node.getPrivateAddresses()));
+        entity.sensors().set(PUBLIC_ADDRESSES, 
ImmutableSet.copyOf(node.getPublicAddresses()));
     }
 
     // 
--------------------------------------------------------------------------------------

Reply via email to