@Override public RunScriptOnNode call() throws Exception { try { return runScriptOnNodeFactory.create(node, script, options).init(); } catch (Exception e) { badNodes.put(node, e); return null; } }
@Override public RunScriptOnNode call() throws Exception { try { return runScriptOnNodeFactory.create(node, script, options).init(); } catch (Exception e) { badNodes.put(node, e); return null; } }
@Override public RunScriptOnNode call() throws Exception { try { return runScriptOnNodeFactory.create(node, script, options).init(); } catch (Exception e) { badNodes.put(node, e); return null; } }
@Override public RunScriptOnNode call() throws Exception { try { return runScriptOnNodeFactory.create(node, script, options).init(); } catch (Exception e) { badNodes.put(node, e); return null; } }
/** * {@inheritDoc} */ @Override public ExecResponse runScriptOnNode(String id, Statement runScript, RunScriptOptions options) { NodeMetadata node = this.getNodeMetadata(id); if (node == null) throw new NoSuchElementException(id); if (node.getStatus() != Status.RUNNING) throw new IllegalStateException("node " + id + " needs to be running before executing a script on it. current state: " + formatStatus(node)); initAdminAccess.visit(runScript); node = updateNodeWithCredentialsIfPresent(node, options); ExecResponse response = runScriptOnNodeFactory.create(node, runScript, options).init().call(); persistNodeCredentials.ifAdminAccess(runScript).apply(node); return response; }
/** * {@inheritDoc} */ @Override public ExecResponse runScriptOnNode(String id, Statement runScript, RunScriptOptions options) { NodeMetadata node = this.getNodeMetadata(id); if (node == null) throw new NoSuchElementException(id); if (node.getStatus() != Status.RUNNING) throw new IllegalStateException("node " + id + " needs to be running before executing a script on it. current state: " + formatStatus(node)); initAdminAccess.visit(runScript); node = updateNodeWithCredentialsIfPresent(node, options); ExecResponse response = runScriptOnNodeFactory.create(node, runScript, options).init().call(); persistNodeCredentials.ifAdminAccess(runScript).apply(node); return response; }
/** * {@inheritDoc} */ @Override public ExecResponse runScriptOnNode(String id, Statement runScript, RunScriptOptions options) { NodeMetadata node = this.getNodeMetadata(id); if (node == null) throw new NoSuchElementException(id); if (node.getStatus() != Status.RUNNING) throw new IllegalStateException("node " + id + " needs to be running before executing a script on it. current state: " + formatStatus(node)); initAdminAccess.visit(runScript); node = updateNodeWithCredentialsIfPresent(node, options); ExecResponse response = runScriptOnNodeFactory.create(node, runScript, options).init().call(); persistNodeCredentials.ifAdminAccess(runScript).apply(node); return response; }
/** * {@inheritDoc} */ @Override public ExecResponse runScriptOnNode(String id, Statement runScript, RunScriptOptions options) { NodeMetadata node = this.getNodeMetadata(id); if (node == null) throw new NoSuchElementException(id); if (node.getStatus() != Status.RUNNING) throw new IllegalStateException("node " + id + " needs to be running before executing a script on it. current state: " + formatStatus(node)); initAdminAccess.visit(runScript); node = updateNodeWithCredentialsIfPresent(node, options); ExecResponse response = runScriptOnNodeFactory.create(node, runScript, options).init().call(); persistNodeCredentials.ifAdminAccess(runScript).apply(node); return response; }