/*
(non-Javadoc)

@see org.duracloud.mill.workman.TaskProcessor#execute()
10040
@Override
    public final void execute() throws TaskExecutionFailedException {
        long startTime = System.currentTimeMillis();

        try {
            executeImpl();
            log.info(createMessage("success", System.currentTimeMillis() - startTime));
        } catch (TaskExecutionFailedException ex) {
            log.error(createMessage("failure", System.currentTimeMillis() - startTime));
            throw ex;
        }
    }
865479
@Override
	public void execute() {
		if (target instanceof WComponentGroup<?>) {
			for (WComponent component : ((WComponentGroup<WComponent>) target).getComponents()) {
				if (component instanceof SubordinateTarget) {
					applyAction((SubordinateTarget) component, value);
				}
			}
		} else {
			// Leaf.
			applyAction(target, value);
		}

	}
729200
@Override
    public void execute() throws BuildException {
        initialize();

        final Job job = getJob(tempDir, getProject());
        try {
            for (final ModuleElem m : modules) {
                m.setProject(getProject());
                m.setLocation(getLocation());
                final PipelineHashIO pipelineInput = new PipelineHashIO();
                for (final Map.Entry<String, String> e : attrs.entrySet()) {
                    pipelineInput.setAttribute(e.getKey(), e.getValue());
                }
                AbstractPipelineModule mod = getPipelineModule(m, pipelineInput);
                long start = System.currentTimeMillis();
                mod.setLogger(logger);
                mod.setJob(job);
                mod.execute(pipelineInput);
                long end = System.currentTimeMillis();
                logger.debug("{0} processing took {1} ms", mod.getClass().getSimpleName(), end - start);
            }
        } catch (final DITAOTException e) {
            throw new BuildException("Failed to run pipeline: " + e.getMessage(), e);
        }
    }
189875
void execute(ExecutableBuilder builder,
            int timeout,
            TimeUnit unit) throws
            CommandLineException,
            InterruptedException, ExecutionException, TimeoutException {
        Future<Void> task = executorService.submit(() -> {
            builder.build().execute();
            return null;
        });
        try {
            if (timeout <= 0) { //Synchronous
                task.get();
            } else { // Guarded execution
                try {
                    task.get(timeout, unit);
                } catch (TimeoutException ex) {
                    // First make the context unusable
                    CommandContext c = builder.getCommandContext();
                    if (c instanceof TimeoutCommandContext) {
                        ((TimeoutCommandContext) c).timeout();
                    }
                    // Then cancel the task.
                    task.cancel(true);
                    throw ex;
                }
            }
        } catch (InterruptedException ex) {
            // Could have been interrupted by user (Ctrl-C)
            Thread.currentThread().interrupt();
            cancelTask(task, builder.getCommandContext(), null);
            // Interrupt running operation.
            CommandContext c = builder.getCommandContext();
            if (c instanceof TimeoutCommandContext) {
                ((TimeoutCommandContext) c).interrupted();
            }
            throw ex;
        }
    }
1106132
public final void execute() {
        try {
            Matcher<R> matcher = createMatcher();
            R result;
            if (input == null && timeout == null) {
                result = getExpect().expect(matcher);
            } else if (timeout == null) {
                result = getExpect().expectIn(input, matcher);
            } else if (input == null) {
                result = getExpect().expect(timeout, matcher);
            } else {
                result = getExpect().expectIn(input, timeout, matcher);
            }
            exportSuccessfulResult(resultPrefix, result);
        } catch (IOException e) {
            throw new BuildException(e);
        }
    }
807972
private void executeTask(DataSourceJdbcTask jdbcTask) {
		JdbcActivity jdbcActivity = jdbcRA.createActivity();
		ActivityContextInterface jdbcACI = jdbcACIF
				.getActivityContextInterface(jdbcActivity);
		jdbcACI.attach(sbbContextExt.getSbbLocalObject());
		jdbcActivity.execute(jdbcTask);
	}
413997
public function execute()
	{
		// Incoming task
		$this->_task = strtolower(Request::getCmd('task', ''));

		$doTask = null;

		// Check if the default task is set
		if (!$this->_task)
		{
			if (isset($this->_taskMap['__default']))
			{
				$doTask = $this->_taskMap['__default'];
			}
		}
		// Check if the task is in the taskMap
		else if (isset($this->_taskMap[$this->_task]))
		{
			$doTask = $this->_taskMap[$this->_task];
		}

		// Raise an error (hopefully, this shouldn't happen)
		if (!$doTask)
		{
			throw new InvalidTaskException(Lang::txt('JLIB_APPLICATION_ERROR_TASK_NOT_FOUND', $this->_task), 404);
		}

		// Record the actual task being fired
		$doTask .= 'Task';

		// Call the task
		$this->$doTask();
	}
110264
public function execute()
    {
        foreach ($this->getJobs() as $key => $job) {
            try {
                $this->console($job, $key + 1);
                $task = $this->createTask($job);
                $return = $task->run();
                $this->getAdapter()->history(HistoryInterface::STATUS_OK, $job, is_string($return) ? $return : null);
            } catch (\Exception $exc) {
                $this->log($job, $exc);
            }
        }

        $this->getAdapter()->finishProcessing($this->getJobs());
    }
1359148
@Override
    public void execute() throws UpdateExecutionException {
        try {
            sync();
            getMarkLogicClient().sendUpdateQuery(getQueryString(), getBindings(), getIncludeInferred(), getBaseURI());
        }catch(ForbiddenUserException | FailedRequestException e){
            throw new UpdateExecutionException(e);
        } catch (RepositoryException e) {
            throw new UpdateExecutionException(e);
        } catch (MalformedQueryException e) {
            throw new UpdateExecutionException(e);
        } catch (IOException e) {
            throw new UpdateExecutionException(e);
        }
    }
326297
@SafeVarargs
    public static <T> void execute(AsyncTask<T, ?, ?> task, T... args) {
        if (Build.VERSION.SDK_INT < Build.VERSION_CODES.DONUT) {
            throw new UnsupportedOperationException("This class can only be used on API 4 and newer.");
        }
        if (Build.VERSION.SDK_INT < Build.VERSION_CODES.HONEYCOMB) {
            task.execute(args);
        } else {
            task.executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, args);
        }
    }
945534
private void executeTaskAsync() {
        final String taskId = currentTask.getId();

        ListenableFuture<?> future = taskExecutorService.submit(currentTask);
        pendingTasks.put(taskId, future);

        future.addListener(new Runnable() {
            @Override
            public void run() {
                pendingTasks.remove(taskId);
            }
        }, MoreExecutors.sameThreadExecutor());

        hasCurrentTask = false;
    }
27552
public void execute() {
		Map<Partition, List<Node>> map = getNodesByPartition();
		for (Partition partition : map.keySet()) {
			List<Node> nodes = map.get(partition);
			partition.execute(nodes);
		}
	}
1086295
public <T> T execute(Callable<T> callable) throws ProcessApplicationExecutionException {
    try {
      return callable.call();
    }
    catch (Exception e) {
      throw LOG.processApplicationExecutionException(e);
    }
  }
1065524
@Override
    public void execute() throws MojoExecutionException, MojoFailureException {
        super.execute();

        // scan classes and build graph
        try {
            processClasspaths();
        } catch (Exception e) {
            throw new MojoExecutionException("Error processing entity classes", e);
        }
    }
225124
private function run(TaskExecutionInterface $execution)
    {
        $start = microtime(true);
        $execution->setStartTime(new \DateTime());
        $execution->setStatus(TaskStatus::RUNNING);
        $this->taskExecutionRepository->save($execution);

        try {
            $execution = $this->hasPassed($execution, $this->handle($execution));
        } catch (ExitException $exception) {
            throw $exception;
        } catch (\Exception $exception) {
            $execution = $this->hasFailed($execution, $exception);
        } finally {
            $this->finalize($execution, $start);
        }
    }
730848
public void execute() {
    Entry head;
    synchronized(this) {
      head = this.head;
      this.head = null;
    }
    while (head != null) {
      try {
        head.runnable.run();
      } catch (Throwable t) {
        platform.reportError("Failure executing runnable: " + head.runnable, t);
      }
      head = head.next;
    }
  }
745172
@Override
    public void execute() throws TaskExecutionFailedException {
        if (AuditTask.ActionType.CREATE_SPACE.name().equals(task.getAction())) {
            String account = task.getAccount();
            log.info("new space audit task received for account {} received: {}", account, task);
            String storeId = task.getStoreId();
            String spaceId = task.getSpaceId();
            log.warn("New space notification: subdomain: {}, storeId: {}, spaceId: {}: ",
                     account, storeId, spaceId);

            newSpace(account,
                     task.getStoreId(),
                     task.getSpaceId(),
                     task.getDateTime(),
                     task.getUserId());
        } else {
            log.debug("This task {} is not a space creation task: it will be ignored.", task);
        }
    }