Issue 534:IndexOutOfBoundsException on problem applying options to node

This commit is contained in:
Adrian Cole 2011-04-19 09:04:28 -07:00
parent be25e4cfad
commit 83bed07d79
1 changed files with 4 additions and 5 deletions

View File

@ -32,7 +32,6 @@ import org.jclouds.ssh.SshClient;
import com.google.common.base.Function; import com.google.common.base.Function;
import com.google.common.base.Predicate; import com.google.common.base.Predicate;
import com.google.common.collect.Iterables;
import com.google.inject.assistedinject.Assisted; import com.google.inject.assistedinject.Assisted;
/** /**
@ -57,10 +56,10 @@ public class RunScriptOnNodeAsInitScriptUsingSshAndBlockUntilComplete extends Ru
boolean complete = runScriptNotRunning.apply(new CommandUsingClient("./" + name + " status", ssh)); boolean complete = runScriptNotRunning.apply(new CommandUsingClient("./" + name + " status", ssh));
logger.debug("<< complete(%s)", complete); logger.debug("<< complete(%s)", complete);
if (logger.isDebugEnabled() || returnVal.getExitCode() != 0) { if (logger.isDebugEnabled() || returnVal.getExitCode() != 0) {
logger.debug("<< stdout from %s as %s@%s\n%s", name, node.getCredentials().identity, Iterables.get(node logger.debug("<< stdout from %s as %s@%s\n%s", name, ssh.getUsername(), ssh.getHostAddress(), ssh.exec(
.getPublicAddresses(), 0), ssh.exec("./" + name + " tail").getOutput()); "./" + name + " tail").getOutput());
logger.debug("<< stderr from %s as %s@%s\n%s", name, node.getCredentials().identity, Iterables.get(node logger.debug("<< stderr from %s as %s@%s\n%s", name, ssh.getUsername(), ssh.getHostAddress(), ssh.exec(
.getPublicAddresses(), 0), ssh.exec("./" + name + " tailerr").getOutput()); "./" + name + " tailerr").getOutput());
} }
return returnVal; return returnVal;
} }