brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ahgittin <...@git.apache.org>
Subject [GitHub] incubator-brooklyn pull request: Minor misc tidies
Date Tue, 12 Aug 2014 14:36:28 GMT
Github user ahgittin commented on a diff in the pull request:

    https://github.com/apache/incubator-brooklyn/pull/113#discussion_r16116508
  
    --- Diff: core/src/main/java/brooklyn/util/osgi/Osgis.java ---
    @@ -195,7 +196,22 @@ private static void installBootBundles(Framework framework) {
             Map<String, Bundle> installedBundles = getInstalledBundles(bundleContext);
             while(resources.hasMoreElements()) {
                 URL url = resources.nextElement();
    -            installExtensionBundle(bundleContext, url, installedBundles, getVersionedId(framework));
    +            ReferenceWithError<Boolean> installResult = installExtensionBundle(bundleContext,
url, installedBundles, getVersionedId(framework));
    +            if (installResult.hasError()) {
    +                if (installResult.getMaskingError()) {
    +                    // true return code means it was installed or trivially not installed
    +                    if (LOG.isTraceEnabled())
    +                        LOG.trace(installResult.getError().getMessage());
    --- End diff --
    
    when "masking errors" are present they are constructed with a message, i think, and the
name of the class is unhelpful so i think `getMessage()` is better.  for critical errors we
log the full trace.


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