Github user nakomis commented on a diff in the pull request:

    https://github.com/apache/brooklyn-server/pull/150#discussion_r66244197
  
    --- Diff: 
software/base/src/main/java/org/apache/brooklyn/entity/software/base/AbstractSoftwareProcessWinRmDriver.java
 ---
    @@ -321,12 +332,21 @@ public int copyTo(InputStream source, String 
destination) {
         }
     
         public void rebootAndWait() {
    +        rebootAndWait(null);
    +    }
    +
    +    public void rebootAndWait(String hostname) {
             try {
    -            executePsScriptNoRetry(ImmutableList.of("Restart-Computer 
-Force"));
    +            if (hostname != null) {
    +                
getLocation().executePsScript(ImmutableMap.of(WinRmTool.COMPUTER_NAME, 
hostname), ImmutableList.of("Restart-Computer -Force"));
    +            } else {
    +                
getLocation().executePsScript(ImmutableList.of("Restart-Computer -Force"));
    +            }
             } catch (Exception e) {
    -            // Restarting the computer will cause the command to fail; 
ignore the exception and continue
    +            LOG.warn("Exception when restarting machine: ", e);
    --- End diff --
    
    My understanding was that this exception was now *not* expected, @bostko is 
that the case?


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