cancel
Showing results for 
Search instead for 
Did you mean: 

[deployment] deploying process definitions and code -suggest

javapapo
Champ in-the-making
Champ in-the-making
Hello to all, my apologies for my initial simple question.

Based on the activiti-engine examples and the demo project I am trying to simplify and break down the steps of deployment in a very simplistic scenario. I am going to have a tomcat installation where I will deploy as the examples indicate my bars, jars and any related elements.

Question1: in case I wanted to isolate the business process code (definitions + java code) in a single 'module' the suggested way would be to have a generic Web App deployment plan  (war) and then throw there any related jar/pars? Is it an exploded war the basis for a start or I would just throw jars and bars just in the class path?

Question2: From the examples I can see that activiti.cfg.xml is being bundled within a specific jar (with the same name) and thrown within the classpath of the server - so that is picked and initialize the engine etc. Is this a suggested way to decouple this configuration file or I could just include activiti.cfg.xml within my jars - part of the simple application above?

Many thanks
3 REPLIES 3

jbarrez
Star Contributor
Star Contributor
(are you THE javapapo?)

Question1: in case I wanted to isolate the business process code (definitions + java code) in a single 'module' the suggested way would be to have a generic Web App deployment plan (war) and then throw there any related jar/pars? Is it an exploded war the basis for a start or I would just throw jars and bars just in the class path?

Yes - in case you want to run the processes isolated, you would need obviously the Activiti engine + jars referenced in your processes.

Putting them in the war is the preferred way (in my opinion), but you also must make sure that the activiti jars are also in the war. Otherwise, you might get strange classloading problems.

Question2: From the examples I can see that activiti.cfg.xml is being bundled within a specific jar (with the same name) and thrown within the classpath of the server - so that is picked and initialize the engine etc. Is this a suggested way to decouple this configuration file or I could just include activiti.cfg.xml within my jars - part of the simple application above?

The only requirement is that the config xml file is found on the classpath. If this is a jar, all is ok. If this is  not in a jar, then you have to make sure your webapp can find it (eg in WEB-INF/classes/ or /lib)

javapapo
Champ in-the-making
Champ in-the-making
Hello Joram, greetings from Athens Smiley Very Happy. I have finally finished my JBPM 3 project and now there is time…for exploring your new tech - looks actually promising..and now I am getting into the details!

Kind Regards
Paris

jbarrez
Star Contributor
Star Contributor
Awesome! Welcome to Activiti!

I'm sure you will feel quickly at home here 😉