brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ahgittin <...@git.apache.org>
Subject [GitHub] brooklyn-server pull request #462: Inherit config default values
Date Mon, 13 Feb 2017 14:45:49 GMT
Github user ahgittin commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/462#discussion_r100808041
  
    --- Diff: core/src/main/java/org/apache/brooklyn/core/config/BasicConfigInheritance.java
---
    @@ -170,12 +324,103 @@ public String getConflictResolutionStrategy() {
             return conflictResolutionStrategy;
         }
         
    +    @Deprecated /** @deprecated since 0.10.0 when it was introduced, prefer {@link #getLocalDefaultResolvesWithAncestorValue()}
*/
         public boolean getUseLocalDefaultValue() {
    -        return useLocalDefaultValue;
    +        return getLocalDefaultResolvesWithAncestorValue();
    +    }
    +
    +    /** see {@link #localDefaultResolvesWithAncestorValue} */
    +    public boolean getLocalDefaultResolvesWithAncestorValue() {
    +        if (localDefaultResolvesWithAncestorValue==null) {
    +            // in case some legacy path is using an improperly deserialized object
    +            log.warn("Encountered legacy "+this+" with null localDefaultResolvesWithAncestorValue;
transforming", new Throwable("stack trace for legacy "+this));
    +            readResolve();
    --- End diff --
    
    i think this should never happen; logging is safety first in case it is


---
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