Examples of DeploymentEntity


Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

   
    if (deploymentId == null) {
      throw new ActivitiIllegalArgumentException("Deployment id is null");
    }
   
    DeploymentEntity deployment = commandContext
            .getDeploymentEntityManager()
            .findDeploymentById(deploymentId);

    if (deployment == null) {
      throw new ActivitiObjectNotFoundException("No deployment found for id = '" + deploymentId + "'", Deployment.class);
    }
   
    // Update category
    deployment.setCategory(category);
   
    if (commandContext.getProcessEngineConfiguration().getEventDispatcher().isEnabled()) {
      commandContext.getProcessEngineConfiguration().getEventDispatcher().dispatchEvent(
          ActivitiEventBuilder.createEntityEvent(ActivitiEventType.ENTITY_UPDATED, deployment));
    }
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

  public ProcessDefinitionEntity resolveProcessDefinition(ProcessDefinitionEntity processDefinition) {
    String processDefinitionId = processDefinition.getId();
    String deploymentId = processDefinition.getDeploymentId();
    processDefinition = processDefinitionCache.get(processDefinitionId);
    if (processDefinition==null) {
      DeploymentEntity deployment = Context
        .getCommandContext()
        .getDeploymentEntityManager()
        .findDeploymentById(deploymentId);
      deployment.setNew(false);
      deploy(deployment, null);
      processDefinition = processDefinitionCache.get(processDefinitionId);
     
      if (processDefinition==null) {
        throw new ActivitiException("deployment '"+deploymentId+"' didn't put process definition '"+processDefinitionId+"' in the cache");
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

  public void removeDeployment(String deploymentId, boolean cascade) {
    DeploymentEntityManager deploymentEntityManager = Context
        .getCommandContext()
        .getDeploymentEntityManager();
   
    DeploymentEntity deployment = deploymentEntityManager.findDeploymentById(deploymentId);
    if(deployment == null)
      throw new ActivitiObjectNotFoundException("Could not find a deployment with id '" + deploymentId + "'.", DeploymentEntity.class);

    // Remove any process definition from the cache
    List<ProcessDefinition> processDefinitions = new ProcessDefinitionQueryImpl(Context.getCommandContext())
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

    return (ProcessDefinitionEntity) execution.getProcessDefinition();
  }

  public DeploymentEntity getDeployment() {
    String deploymentId = getProcessDefinition().getDeploymentId();
    DeploymentEntity deployment = Context
      .getCommandContext()
      .getDeploymentEntityManager()
      .findDeploymentById(deploymentId);
    return deployment;
  }
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

      .getDeploymentManager()
      .getKnowledgeBaseCache();
 
    KnowledgeBase knowledgeBase = (KnowledgeBase) knowledgeBaseCache.get(deploymentId);
    if (knowledgeBase==null) {
      DeploymentEntity deployment = Context
        .getCommandContext()
        .getDeploymentEntityManager()
        .findDeploymentById(deploymentId);
      if (deployment==null) {
        throw new ActivitiObjectNotFoundException("no deployment with id "+deploymentId, Deployment.class);
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

    return (ProcessDefinitionEntity) execution.getProcessDefinition();
  }

  public DeploymentEntity getDeployment() {
    String deploymentId = getProcessDefinition().getDeploymentId();
    DeploymentEntity deployment = Context
      .getCommandContext()
      .getDeploymentManager()
      .findDeploymentById(deploymentId);
    return deployment;
  }
View Full Code Here

Examples of org.activiti.engine.impl.persistence.entity.DeploymentEntity

      .getDeploymentCache()
      .getKnowledgeBaseCache();
 
    KnowledgeBase knowledgeBase = (KnowledgeBase) knowledgeBaseCache.get(deploymentId);
    if (knowledgeBase==null) {
      DeploymentEntity deployment = Context
        .getCommandContext()
        .getDeploymentManager()
        .findDeploymentById(deploymentId);
      if (deployment==null) {
        throw new ActivitiException("no deployment with id "+deploymentId);
View Full Code Here

Examples of org.camunda.bpm.engine.impl.persistence.entity.DeploymentEntity

  @Before
  public void setUp() {
    context = new CmmnHandlerContext();

    DeploymentEntity deployment = new DeploymentEntity();
    deployment.setId("aDeploymentId");

    context.setDeployment(deployment);
    context.setModel(modelInstance);
  }
View Full Code Here

Examples of org.camunda.bpm.engine.impl.persistence.entity.DeploymentEntity

  public ProcessDefinitionEntity resolveProcessDefinition(ProcessDefinitionEntity processDefinition) {
    String processDefinitionId = processDefinition.getId();
    String deploymentId = processDefinition.getDeploymentId();
    ProcessDefinitionEntity cachedProcessDefinition = processDefinitionCache.get(processDefinitionId);
    if (cachedProcessDefinition==null) {
      DeploymentEntity deployment = Context
        .getCommandContext()
        .getDeploymentManager()
        .findDeploymentById(deploymentId);
      deployment.setNew(false);
      deploy(deployment);
      cachedProcessDefinition = processDefinitionCache.get(processDefinitionId);

      ensureNotNull("deployment '" + deploymentId + "' didn't put process definition '" + processDefinitionId + "' in the cache", "cachedProcessDefinition", cachedProcessDefinition);
    } else {
View Full Code Here

Examples of org.camunda.bpm.engine.impl.persistence.entity.DeploymentEntity

    String deploymentId = caseDefinition.getDeploymentId();

    CaseDefinitionEntity cachedCaseDefinition = caseDefinitionCache.get(caseDefinitionId);

    if (cachedCaseDefinition==null) {
      DeploymentEntity deployment = Context
        .getCommandContext()
        .getDeploymentManager()
        .findDeploymentById(deploymentId);

      deployment.setNew(false);
      deploy(deployment);

      cachedCaseDefinition = caseDefinitionCache.get(caseDefinitionId);

      ensureNotNull("deployment '" + deploymentId + "' didn't put case definition '" + caseDefinitionId + "' in the cache", "cachedCaseDefinition", cachedCaseDefinition);
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.