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 #746: Auto wrap YAML BOMs as catalog bundles
Date Tue, 18 Jul 2017 08:08:07 GMT
Github user ahgittin commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/746#discussion_r127907530
  
    --- Diff: core/src/main/java/org/apache/brooklyn/core/mgmt/ha/OsgiArchiveInstaller.java
---
    @@ -336,14 +358,14 @@ private synchronized void close() {
                 if (!updating) { 
                     osgiManager.managedBundlesRecord.addManagedBundle(result);
                     result.code = OsgiBundleInstallationResult.ResultCode.INSTALLED_NEW_BUNDLE;
    -                result.message = "Installed "+result.getMetadata().getVersionedName()+"
with ID "+result.getMetadata().getId();
    +                result.message = "Installed Brooklyn catalog bundle "+result.getMetadata().getVersionedName()+"
with ID "+result.getMetadata().getId()+" ["+result.bundle.getBundleId()+"]";
    --- End diff --
    
    @geomacy have pushed tests which confirm the logic to delete now-empty bundles is working
correctly when it runs for items like this (the idea is if you add a second catalog with the
same items as the first, the items become attached to the second so the first one is empty
and we delete it).
    
    i suspect in the problem you describe that for some reason it wasn't being triggered,
either on startup or on rebind.  if you added another BOM it would probably clean out the
old items.
    
    we could run the "delete empties" more often but i'm inclined not to given it's already
a warning to add something without a bundle declared and there's a workaround.
    
    I've added the `bundle` declaration at:  https://github.com/apache/brooklyn-dist/pull/99
    
    A related recommended improvement would be to put `catalog.bom` into each of the `brooklyn-library`
sub-projects, and ensure that those bundles are referenced and installed as brooklyn-managed
bundles in the `default.catalog.bom` (or the `library-*.bom` it calls).  Not that important
however as we want to move away from those java library items in any case.  More important
for yaml bundles in blueprint repo to follow the new pattern.


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