brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From geomacy <>
Subject [GitHub] brooklyn-server issue #719: Check versionedName to avoid NPE.
Date Tue, 06 Jun 2017 16:44:59 GMT
Github user geomacy commented on the issue:
    Hm very strange - it looks as if the test hasn't pulled the [change](,
    Copying the relevant lines as the above will be thrown away on next rebuild:
            public static BundleInstallationRestResult of(OsgiBundleInstallationResult in,
ManagementContext mgmt, BrooklynRestResourceUtils brooklynU, UriInfo ui) {
                BundleInstallationRestResult result = new BundleInstallationRestResult();
                result.message = in.getMessage();
                result.bundle = in.getMetadata().getVersionedName().toString();
                result.code = in.getCode();
                if (in.getCatalogItemsInstalled()!=null) {
                    result.types = MutableMap.of();
                    for (String id: in.getCatalogItemsInstalled()) {
                        // TODO prefer to use RegisteredType, but we need transformer for
those in REST
                        //RegisteredType ci = mgmt.getTypeRegistry().get(id);
                        CatalogItem<?, ?> ci = CatalogUtils.getCatalogItemOptionalVersion(mgmt,
                        CatalogItemSummary summary = CatalogTransformer.catalogItemSummary(brooklynU,
ci, ui.getBaseUriBuilder());
                        result.types.put(id, summary);
                return result;
    Note the line 
                result.bundle = in.getMetadata().getVersionedName().toString();
    which doesn't include the change linked above.

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

View raw message