AnsweredAssumed Answered

Deploy new .bar-File from running process

Question asked by krigu on Oct 29, 2013
Latest reply on Oct 31, 2013 by krigu
We've built a process that allows administrators to deploy their .bar-files. However, the process and the code below worked fine with the Actviti 5.10. Now we upgraded to 5.14 and it seems like the process doesn't get deployed any more.

The code is (a bit simplyfied):

public class DeployProcessUtil implements JavaDelegate {

   public void execute(DelegateExecution execution) throws Exception {

      RepositoryService repo = ActivitiUtil.getRepositoryService();
      DeploymentBuilder deploymentBuilder = repo.createDeployment();

      try {
                        // getBarFile() loads the .bar-file as byte[]
         deploymentBuilder.addZipInputStream(new ZipInputStream(new ByteArrayInputStream(getBarFile()));
      } catch (Exception e) {
         throw new RuntimeException(e.getMessage());

      org.activiti.engine.repository.Deployment deployment = deploymentBuilder.deploy();

                // There is only one deployed process, but there should be two
      System.out.println("Process: " + ActivitiUtil.getRepositoryService().createProcessDefinitionQuery().list());


After the call of the deploy()-method, there is still only one process available instead of two. The above code works fine in a standalone JUnit-Testcase and worked before Activiti 5.11, so I guess the .bar-File should be ok.

So are there any suggestions what could case this problem or how to solve it?