Package org.jbpm.pvm.internal.cmd

Examples of org.jbpm.pvm.internal.cmd.CommandService.execute()


    if (userId!=null) {
      environment.setUserId(userId);
    }
    try {
      CommandService commandService = environment.get(CommandService.class);
      commandService.execute(command);
    } finally {
      if (userId!=null) {
        environment.setUserId(null);
      }
    }
View Full Code Here


  }

  protected Collection<Long> acquireJobs() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Collection<Long>> acquireJobsCommand = jobExecutor.getAcquireJobsCommand();
    return commandService.execute(acquireJobsCommand);
  }

  protected Date getNextDueDate() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Date> getNextDueDate = jobExecutor.getNextDueDateCommand();
View Full Code Here

  }

  protected Date getNextDueDate() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Date> getNextDueDate = jobExecutor.getNextDueDateCommand();
    return commandService.execute(getNextDueDate);
  }

  protected long getWaitPeriod() {
    long interval = jobExecutor.getIdleMillis();
    Date nextDueDate = getNextDueDate();
View Full Code Here

            jobDbids = queue.take();
            log.debug("took job(s) "+jobDbids+" from queue");

            for (Long jobDbid: jobDbids) {
              CommandService commandService = jobExecutor.getCommandExecutor();
              commandService.execute(new ExecuteJobCmd(jobDbid));
            }
          } catch (InterruptedException e) {
            log.trace("waiting for acquired jobs got interrupted");
          } catch (Exception e) {
            log.error("exception in job executor thread", e);
View Full Code Here

  } */

  public <T> T execute(Command<T> command) {
    log.info("Execute " + command);
    CommandService cmd = processEngine.get(CommandService.class);
    return cmd.execute(command);
  }

  public void setSessionContext(SessionContext sessionContext) {
    this.sessionContext = sessionContext;
  }
View Full Code Here

    if (userId!=null) {
      environment.setAuthenticatedUserId(userId);
    }
    try {
      CommandService commandService = environment.get(CommandService.class);
      commandService.execute(command);
    } finally {
      if (userId!=null) {
        environment.setAuthenticatedUserId(null);
      }
    }
View Full Code Here

  }

  protected Collection<Long> acquireJobs() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Collection<Long>> acquireJobsCommand = jobExecutor.getAcquireJobsCommand();
    return commandService.execute(acquireJobsCommand);
  }

  protected Date getNextDueDate() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Date> getNextDueDate = jobExecutor.getNextDueDateCommand();
View Full Code Here

  }

  protected Date getNextDueDate() {
    CommandService commandService = jobExecutor.getCommandExecutor();
    Command<Date> getNextDueDate = jobExecutor.getNextDueDateCommand();
    return commandService.execute(getNextDueDate);
  }

  protected long getWaitPeriod() {
    long interval = jobExecutor.getIdleMillis();
    Date nextDueDate = getNextDueDate();
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.