AnsweredAssumed Answered

Multiple deploy with embedded Activiti (SOLVED)

Question asked by michele1 on Jul 26, 2011
Hello to all!
This is my first question, about the activiti engine, followed shortly by another question.

I have succesfully put an embedded Activiti engine into a standalone java application, that is run from the client and connects via jdbc to a remote database.

I could have a series of processes, and I deploy them every time the app is stated with this code:


final DeploymentBuilder deployementBuilder = this.repositoryService .createDeployment();
   for (String path : paths) {
      // I have a list of URL pointing to bpmn on the filesystem
      URL url;
      url = new URL(path);
      URLConnection uc = url.openConnection();
// try to read the data ad inputStream
      InputStream input = uc.getInputStream();
      deployementBuilder.addInputStream(url.toString(), input);
      input.close();

   }
// deploy and pass back the deploy handler
   Deployment ret = deployementBuilder.deploy();
   return ret;
}

This snippet is run every time the app is started. The problem I hava is that every time the app is run i gon a new deployment even if the file is not modified.

I think I'm missing something obvious either in the process definitions or in the way I call the deploymentBuilder, but now I have no clue where the problem is.

Any help is appreciated.

UPDATE: found this thread: http://forums.activiti.org/en/viewtopic.php?f=6&t=1524

So i made a fix pathcing the activiti-engine jar of the 5.6 version, modifing the query on the database and annded in the classpath the png name.
Seems to me that the patched version is qorking.

Mike

Outcomes