GitHub user aledsage opened a pull request:

    https://github.com/apache/incubator-brooklyn/pull/1138

    YAML: don’t wrap sub-entities in BasicApplication

    Previously, any catalog item of type “template” would always be wrapped
    in a BasicApplication. This was being done in three places. The first
    is ok; the second two are bad:
    
    1. When deploying a top-level “template” from the catalog.
    2. When referring to a “template” catalog item in a member-spec (e.g.
       for a DynamicCluster)
    3. When referring to a “template” catalog item in brooklyn.children.
    
    @johnmccabe @ahgittin @neykov you'll be interested in this.
    
    I don't like the approach (duplicating the fix in three places, to remove 
the wrapping app, for the different contexts that it might be used).
    
    It would feel better for the YAML-parsing to *not* wrap the entity at all, 
unless there was a really good reason to (e.g. the catalog item consists of 
multiple top-level services defined in its yaml). The caller could then decide 
if it needs to wrap it (i.e. if deliberately creating a top-level app), or 
leave as-is.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/aledsage/incubator-brooklyn 
fix/wraps-sub-entities-in-BasicApplication

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/incubator-brooklyn/pull/1138.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1138
    
----
commit e3a16614055f83f68164d6cfe222668710a4f953
Author: Aled Sage <[email protected]>
Date:   2016-01-12T16:55:01Z

    YAML: don’t wrap sub-entities in BasicApplication
    
    Previously, any catalog item of type “template” would always be wrapped
    in a BasicApplication. This was being done in three places. The first
    is ok; the second two are bad:
    
    1. When deploying a top-level “template” from the catalog.
    2. When referring to a “template” catalog item in a member-spec (e.g.
       for a DynamicCluster)
    3. When referring to a “template” catalog item in brooklyn.children.

----


---
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 [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to