Examples of StatementOnNodeFailure


Examples of org.jclouds.compute.events.StatementOnNodeFailure

      logger.debug("<< cancelled(%s)", commandRunner.getStatement().getInstanceName());
      ExecResponse returnVal = commandRunner.refreshAndRunAction("stop");
      CancellationException e = new CancellationException(String.format(
               "cancelled %s on node: %s; stop command had exit status: %s", getCommandRunner().getStatement()
                        .getInstanceName(), getCommandRunner().getNode().getId(), returnVal));
      eventBus.post(new StatementOnNodeFailure(getCommandRunner().getStatement(), getCommandRunner().getNode(), e));
      super.interruptTask();
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

      logger.debug("<< cancelled(%s)", commandRunner.getStatement().getInstanceName());
      ExecResponse returnVal = commandRunner.refreshAndRunAction("stop");
      CancellationException e = new CancellationException(String.format(
               "cancelled %s on node: %s; stop command had exit status: %s", getCommandRunner().getStatement()
                        .getInstanceName(), getCommandRunner().getNode().getId(), returnVal));
      eventBus.post(new StatementOnNodeFailure(getCommandRunner().getStatement(), getCommandRunner().getNode(), e));
      super.interruptTask();
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

            }

         });
         return runAction("start");
      } catch (Throwable e) {
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw Throwables.propagate(e);
      }
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

         String command = runAsRoot ? execAsRoot(statement.render(OsFamily.UNIX)) : execScriptAsDefaultUser(statement
               .render(OsFamily.UNIX));
         try {
            returnVal = runCommand(command);
         } catch (Throwable e) {
            eventBus.post(new StatementOnNodeFailure(statement, node, e));
            throw Throwables.propagate(e);
         }
         eventBus.post(new StatementOnNodeCompletion(statement, node, returnVal));
         if (logger.isTraceEnabled())
            logger.trace("<< %s[%s]", statement, returnVal);
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

   @Override
   public ExecResponse doCall() {
      try {
         return future().get(timeouts.scriptComplete, TimeUnit.MILLISECONDS);
      } catch (Throwable e) {
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw Throwables.propagate(e);
      }
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

      ExecResponse returnVal = super.doCall();
      if (returnVal.getExitStatus() != 0) {
         IllegalStateException e = new IllegalStateException(String.format(
               "instance: %s on node: %s had non-zero exit status: %s", init.getInstanceName(), getNode().getId(),
               returnVal));
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw e;
      }
      return statusFactory.create(this).init();
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

            }

         });
         return runAction("start");
      } catch (Throwable e) {
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw Throwables.propagate(e);
      }
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

         String command = runAsRoot ? execAsRoot(statement.render(OsFamily.UNIX)) : execScriptAsDefaultUser(statement
               .render(OsFamily.UNIX));
         try {
            returnVal = runCommand(command);
         } catch (Throwable e) {
            eventBus.post(new StatementOnNodeFailure(statement, node, e));
            throw Throwables.propagate(e);
         }
         eventBus.post(new StatementOnNodeCompletion(statement, node, returnVal));
         if (logger.isTraceEnabled())
            logger.trace("<< %s[%s]", statement, returnVal);
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

   @Override
   public ExecResponse doCall() {
      try {
         return future().get(timeouts.scriptComplete, TimeUnit.MILLISECONDS);
      } catch (Throwable e) {
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw Throwables.propagate(e);
      }
   }
View Full Code Here

Examples of org.jclouds.compute.events.StatementOnNodeFailure

      ExecResponse returnVal = super.doCall();
      if (returnVal.getExitStatus() != 0) {
         IllegalStateException e = new IllegalStateException(String.format(
               "instance: %s on node: %s had non-zero exit status: %s", init.getInstanceName(), getNode().getId(),
               returnVal));
         eventBus.post(new StatementOnNodeFailure(init, node, e));
         throw e;
      }
      return statusFactory.create(this).init();
   }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.