brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sjcorbett <...@git.apache.org>
Subject [GitHub] incubator-brooklyn pull request: Rebind read only
Date Wed, 01 Oct 2014 16:16:42 GMT
Github user sjcorbett commented on a diff in the pull request:

    https://github.com/apache/incubator-brooklyn/pull/197#discussion_r18289228
  
    --- Diff: core/src/main/java/brooklyn/management/internal/NonDeploymentLocationManager.java
---
    @@ -72,11 +72,30 @@ public Location getLocation(String id) {
         }
     
         @Override
    +    public Iterable<String> getLocationIds() {
    +        if (isInitialManagementContextReal()) {
    +            return ((LocationManagerInternal)initialManagementContext.getLocationManager()).getLocationIds();
    +        } else {
    +            return null;
    --- End diff --
    
    Is `RebindManagerImpl` ever be used with a `NonDeploymentManagementContext`? This will
throw an NPE if it yes. Safer to return an empty iterable.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message