Package org.camunda.bpm.engine

Examples of org.camunda.bpm.engine.ProcessEngineException


    if(eventSubprocessActivity != null) {
      execution.executeActivity(eventSubprocessActivity);

    } else {
      throw new ProcessEngineException("Error while triggering event subprocess using timer start event: cannot find activity with id '"+configuration+"'.");
    }

  }
View Full Code Here


    return this;
  }

  public HistoricIncidentQuery open() {
    if (incidentState != null) {
      throw new ProcessEngineException("Already querying for incident state <" + incidentState + ">");
    }
    incidentState = IncidentState.DEFAULT;
    return this;
  }
View Full Code Here

    return this;
  }

  public HistoricIncidentQuery resolved() {
    if (incidentState != null) {
      throw new ProcessEngineException("Already querying for incident state <" + incidentState + ">");
    }
    incidentState = IncidentState.RESOLVED;
    return this;
  }
View Full Code Here

    return this;
  }

  public HistoricIncidentQuery deleted() {
    if (incidentState != null) {
      throw new ProcessEngineException("Already querying for incident state <" + incidentState + ">");
    }
    incidentState = IncidentState.DELETED;
    return this;
  }
View Full Code Here

        .getBusinessCalendarManager()
        .getBusinessCalendar(type.calendarName);

    if (description==null) {
      // Prevent NPE from happening in the next line
      throw new ProcessEngineException("Timer '"+execution.getActivityId()+"' was not configured with a valid duration/time");
    }

    String dueDateString = null;
    Date duedate = null;

    // ACT-1415: timer-declaration on start-event may contain expressions NOT
    // evaluating variables but other context, evaluating should happen nevertheless
    VariableScope scopeForExpression = execution;
    if(scopeForExpression == null) {
      scopeForExpression = StartProcessVariableScope.getSharedInstance();
    }

    Object dueDateValue = description.getValue(scopeForExpression);
    if (dueDateValue instanceof String) {
      dueDateString = (String)dueDateValue;
    }
    else if (dueDateValue instanceof Date) {
      duedate = (Date)dueDateValue;
    }
    else {
      throw new ProcessEngineException("Timer '"+execution.getActivityId()+"' was not configured with a valid duration/time, either hand in a java.util.Date or a String in format 'yyyy-MM-dd'T'hh:mm:ss'");
    }

    if (duedate==null) {
      duedate = businessCalendar.resolveDuedate(dueDateString);
    }
View Full Code Here

      log.log(Level.SEVERE, "exception during timer execution", e);
      throw e;

    } catch (Exception e) {
      log.log(Level.SEVERE, "exception during timer execution", e);
      throw new ProcessEngineException("exception during timer execution: " + e.getMessage(), e);
    }
  }
View Full Code Here

    } else if (delegateInstance instanceof JavaDelegate) {
      return new ServiceTaskJavaDelegateActivityBehavior((JavaDelegate) delegateInstance);

    } else {
      throw new ProcessEngineException(delegateInstance.getClass().getName()+" doesn't implement "+ExecutionListener.class+" nor "+JavaDelegate.class);
    }
  }
View Full Code Here

    String operationName = null;
    String transitionId = null;
    if (configuration.contains("$")) {
      String[] configParts = configuration.split("\\$");
      if (configParts.length != 2) {
        throw new ProcessEngineException("Illegal async continuation job handler configuration: '" + configuration + "': exprecting two parts seperated by '$'.");
      }
      operationName = configParts[0];
      transitionId = configParts[1];

    } else {
View Full Code Here

    } else if (delegate instanceof JavaDelegate) {
      Context.getProcessEngineConfiguration()
        .getDelegateInterceptor()
        .handleInvocation(new JavaDelegateInvocation((JavaDelegate) delegate, execution));
    } else {
      throw new ProcessEngineException("Delegate expression " + expression
              + " did not resolve to an implementation of " + ExecutionListener.class
              + " nor " + JavaDelegate.class);
    }
  }
View Full Code Here

      } catch (InterruptedException e) {
      } finally {
        timer.cancel();
      }
      if (areJobsAvailable) {
        throw new ProcessEngineException("time limit of " + maxMillisToWait + " was exceeded");
      }

    } finally {
      jobExecutor.shutdown();
    }
View Full Code Here

TOP

Related Classes of org.camunda.bpm.engine.ProcessEngineException

Copyright © 2018 www.massapicom. 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.