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 13:04:45 GMT
Github user ahgittin commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/462#discussion_r100788414
  
    --- Diff: core/src/main/java/org/apache/brooklyn/core/objs/BasicSpecParameter.java ---
    @@ -404,7 +431,126 @@ public static void addParameters(AbstractBrooklynObjectSpec<?,
?> spec, List<? e
                 spec.parametersAdd(BasicSpecParameter.fromSpec(loader.getManagementContext(),
spec));
             }
             if (explicitParams.size() > 0) {
    -            spec.parametersAdd(explicitParams);
    +            spec.parametersReplace(resolveParameters(explicitParams, spec.getParameters(),
spec));
    +        }
    +    }
    +
    +    /** merge parameters against other parameters and known and type-inherited config
keys */
    +    static Collection<SpecParameter<?>> resolveParameters(Collection<?
extends SpecParameter<?>> newParams, Collection<? extends SpecParameter<?>>
existingReferenceParamsToKeep, AbstractBrooklynObjectSpec<?,?> spec) {
    --- End diff --
    
    it would be needed for the `TODO` section


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