Examples of ExecutionException


Examples of br.net.woodstock.rockframework.ExecutionException

    try {
      StringWriter writer = new StringWriter();
      this.write(writer);
      return writer.toString();
    } catch (IOException e) {
      throw new ExecutionException(e);
    }
  }
View Full Code Here

Examples of com.alibaba.dubbo.remoting.ExecutionException

        }
    }

    public void caught(Channel channel, Throwable exception) throws RemotingException {
        if (exception instanceof ExecutionException) {
            ExecutionException e = (ExecutionException) exception;
            Object msg = e.getRequest();
            if (msg instanceof Request) {
                Request req = (Request) msg;
                if (req.isTwoWay() && ! req.isHeartbeat()) {
                    Response res = new Response(req.getId(), req.getVersion());
                    res.setStatus(Response.SERVER_ERROR);
View Full Code Here

Examples of com.aragost.javahg.commands.ExecutionException

        }

        doneHook();

        if (!isSuccessful()) {
            throw new ExecutionException(this);
        }
    }
View Full Code Here

Examples of com.cloud.utils.exception.ExecutionException

            primaryStorage = _storagePoolDao.lockRow(primaryStorageId, true);

            if (primaryStorage == null) {
                String msg = "Unable to obtain lock on the storage pool record in preparePrimaryStorageForMaintenance()";
                s_logger.error(msg);
                throw new ExecutionException(msg);
            }

            List<StoragePoolVO> spes = _storagePoolDao.listBy(primaryStorage.getDataCenterId(), primaryStorage.getPodId(), primaryStorage.getClusterId());
            for (StoragePoolVO sp : spes) {
                if (sp.getStatus() == StoragePoolStatus.PrepareForMaintenance) {
View Full Code Here

Examples of com.dtolabs.rundeck.core.execution.ExecutionException

                                       final String[] args) throws ExecutionException {
        final String commandexecutable;
        final String[] commandargs;

        if (!command && null == scriptfile) {
            throw new ExecutionException("Could not determine the command to dispatch");
        }
        if ("windows".equals(nodeentry.getOsFamily())) {
            //TODO: escape args properly for windows
            commandexecutable = "cmd.exe";
            if (command) {
                ArrayList<String> list = new ArrayList<String>();
                list.add(0, "/c");
                list.addAll(Arrays.asList(args));
                commandargs = list.toArray(new String[list.size()]);
            } else if (null != scriptfile) {
                //commandString is the script file location
                ArrayList<String> list = new ArrayList<String>();
                list.add(scriptfile.getAbsolutePath());
                if(args!=null && args.length>0){
                    list.addAll(Arrays.asList(args));
                }
                list.add(0,"/c");
                commandargs = list.toArray(new String[list.size()]);
            } else {
                throw new ExecutionException("Could not determine the command to dispatch");
            }
        } else {
            if (command) {
                commandexecutable = "/bin/sh";
                commandargs = new String[]{"-c", StringUtils.join(args, " ")};
            } else if (null != scriptfile) {
                final String scriptPath = scriptfile.getAbsolutePath();
                commandexecutable = scriptPath;
                commandargs=args;
            } else {
                throw new ExecutionException("Could not determine the command to dispatch");
            }
        }
        return new ExecTaskParameters() {
            public String getCommandexecutable() {
                return commandexecutable;
View Full Code Here

Examples of com.intellij.execution.ExecutionException

                                           ExecutionEnvironment env) throws ExecutionException {
    final HaxeApplicationConfiguration configuration = (HaxeApplicationConfiguration)env.getRunProfile();
    final Module module = configuration.getConfigurationModule().getModule();

    if (module == null) {
      throw new ExecutionException(HaxeBundle.message("no.module.for.run.configuration", configuration.getName()));
    }

    final HaxeModuleSettings settings = HaxeModuleSettings.getInstance(module);

    if (settings.isUseNmmlToBuild()) {
      final NMERunningState nmeRunningState = new NMERunningState(env, module, false);
      return super.doExecute(project, nmeRunningState, contentToReuse, env);
    }

    if (settings.isUseOpenFLToBuild()) {
      final OpenFLRunningState openflRunningState = new OpenFLRunningState(env, module, true);
      return super.doExecute(project, openflRunningState, contentToReuse, env);
    }

    if (configuration.isCustomFileToLaunch() && FileUtilRt.extensionEquals(configuration.getCustomFileToLaunchPath(), "n")) {
      final NekoRunningState nekoRunningState = new NekoRunningState(env, module, configuration.getCustomFileToLaunchPath());
      return super.doExecute(project, nekoRunningState, contentToReuse, env);
    }

    if (configuration.isCustomExecutable()) {
      final String filePath = configuration.isCustomFileToLaunch()
                              ? configuration.getCustomFileToLaunchPath()
                              : getOutputFilePath(module, settings);
      return super.doExecute(project, new CommandLineState(env) {
        @NotNull
        @Override
        protected ProcessHandler startProcess() throws ExecutionException {
          final GeneralCommandLine commandLine = new GeneralCommandLine();
          commandLine.setWorkDirectory(PathUtil.getParentPath(module.getModuleFilePath()));
          commandLine.setExePath(configuration.getCustomExecutablePath());
          commandLine.addParameter(filePath);

          final TextConsoleBuilder consoleBuilder = TextConsoleBuilderFactory.getInstance().createBuilder(module.getProject());
          setConsoleBuilder(consoleBuilder);

          return new OSProcessHandler(commandLine.createProcess(), commandLine.getCommandLineString());
        }
      }, contentToReuse, env);
    }

    if (configuration.isCustomFileToLaunch()) {
      BrowserUtil.open(configuration.getCustomFileToLaunchPath());
      return null;
    }

    if (settings.getHaxeTarget() == HaxeTarget.FLASH) {
      BrowserUtil.open(getOutputFilePath(module, settings));
      return null;
    }

    if (settings.getHaxeTarget() != HaxeTarget.NEKO) {
      throw new ExecutionException(HaxeBundle.message("haxe.run.wrong.target", settings.getHaxeTarget()));
    }

    final NekoRunningState nekoRunningState = new NekoRunningState(env, module, null);
    return super.doExecute(project, nekoRunningState, contentToReuse, env);
  }
View Full Code Here

Examples of com.liferay.portal.kernel.scripting.ExecutionException

                                          final Map<String, Object> inputObjects,
                                          final Set<String> outputNames,
                                          final String script) throws ScriptingException {

        if (allowedClasses != null && !allowedClasses.isEmpty()) {
            throw new ExecutionException("Constrained execution not supported for Clojure");
        }

        final Callable<Map<String, Object>> callable = createCallableForScript(inputObjects, outputNames, script);

        return callAndWrapException(callable);
View Full Code Here

Examples of com.scooterframework.common.exception.ExecutionException

        try {
            Method m = getMethod(instance.getClass(), methodName);
            result = m.invoke(instance, args);
        }
        catch(Exception ex) {
            throw new ExecutionException(instance.getClass().getName(), methodName, args, ex);
        }
        return result;
    }
View Full Code Here

Examples of de.matrixweb.smaller.clients.common.ExecutionException

                manifest, target);
          } finally {
            vfs.dispose();
          }
        } catch (final IOException e) {
          throw new ExecutionException("Embedded smaller failed", e);
        } finally {
          processorFactory.dispose();
        }
      }
    };
View Full Code Here

Examples of gate.creole.ExecutionException

    startup();
  }

  public void startup() throws ExecutionException {
    if (getAnnotationSpecifications() == null || getAnnotationSpecifications().isEmpty()) {
      throw new ExecutionException("SourceSpecifications must not be empty");
    }
    if(insertSpace) {
      processingOptions.put("separator"," ");
    } else {
      if(processingOptions.containsKey("separator")) {
        processingOptions.remove("separator");
      }
    }
    try {
      annotatedDocumentTransformer =
        new AnnotatedDocumentTransformer(
        getAnnotationSpecifications(), processingOptions,
        false, true);
    } catch (InvalidNameException ex) {
      throw new ExecutionException(ex);
    }

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