brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From neykov <...@git.apache.org>
Subject [GitHub] brooklyn-server pull request #207: Ensure detection of failed pre.install.co...
Date Thu, 16 Jun 2016 16:46:40 GMT
Github user neykov commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/207#discussion_r67381349
  
    --- Diff: software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessSshDriver.java
---
    @@ -285,45 +296,54 @@ public void copyInstallResources() {
             }
         }
     
    +    private void executeSuccessfully(ConfigKey<String> configKey, String label)
{
    +        log.debug("Executing {} on entity {}", label, entity.getDisplayName());
    +        int result = execute(ImmutableList.of(getEntity().getConfig(configKey)), label);
    +        if (0 != result) {
    +            log.debug("Executing {} failed with return code {}", label, result);
    +            throw new IllegalStateException("commands for " + configKey.getName() + "
failed with return code " + result);
    --- End diff --
    
    Don't think `execute` logs the stdin/stdout/stderr on error - could be useful. For the
time being a TODO here will do.


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