GitHub user neykov opened a pull request:

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

    [WIP] Refactoring camp dependencies

    This is a work in progress, but it might be too controversial so I am 
posting it early to gather comments.
    What I noticed while working on the camp/catalog tasks was that there was a 
lot of code repetition trying to create entities/specs from camp at various 
places in the code. That code also made core unnecessarily depend on camp-base 
using it just for intermediate results on the way to specs/entities. Here is an 
attempt to solve this by:
      * changing brooklyn-core not to depend on camp-base. Instead plugins (in 
this case offered by brooklyn-camp) are responsible for parsing the input and 
creating EntitySpecs from it. The idea is to use the approach for different 
types of inputs, not just camp yaml, while avoiding pulling in dependencies 
into core.
      * Extract all the code that uses PdpMatcher.parseDeploymentPlan + 
AssemblyTemplateSpecInstantiator.createSpec/instantiate pairs in a common place 
- a lot of code repetition
    
    The changes pass a full build with tests and a simple catalog + app yaml 
instantiation, but are not yet thoroughly reviewed. Adding tests would be 
needed for the new funcitonality in brooklyn-camp.
     

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

    $ git pull https://github.com/neykov/incubator-brooklyn 
refactor-camp-dependencies

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

    https://github.com/apache/incubator-brooklyn/pull/100.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 #100
    
----
commit 9827ea7cda3fb490e6bd5289ca6f3a49040102c5
Author: Svetoslav Neykov <[email protected]>
Date:   2014-07-28T15:52:42Z

    Refactoring camp dependencies
    
      * brooklyn-core doesn't know about CAMP any more, instead plugins (in 
this case brooklyn-camp) are responsible for parsing the input and creating 
EntitySpecs from it. The idea is to use the approach for different inputs, 
while avoiding pulling in dependencies into core.
      * Extract all the code that uses PdpMatcher.parseDeploymentPlan + 
AssemblyTemplateSpecInstantiator.createSpec/instantiate pairs in a common place 
- a lot of code repetition

----


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