cancel
Showing results for 
Search instead for 
Did you mean: 

Integrating REST interface / explore into an existing webapp

sebastian_s
Champ in-the-making
Champ in-the-making
Hello everybody,

I am struggling integrating the Activiti REST interface into an existing web application since the REST interface is already an .war-artifact itself. For this reason I would like to propose to change the way the REST interface is build in the following way.

What about creating a .jar with the actual API and servlet classes and then creating a web-app (.jar) which references the .jar with the actual API classes. The .war would then contain the rest-api.jar plus the configuration files / examples. In my opinion this would ease the integration and usage of the REST interface since you could use the "rest-api.jar" in your own web application.

Any opinions on this?

EDIT: The same goes for the explorer. Anyway, I managed to pack a jar for the explorer and to add it to the dependencies of my webapp. The problem I am facing now however is that I cannot convince the explorer to use my process engine instance which has been created by a Spring configuration file already because it is in the contextConfigLocation. The explorer always tries to get the default Process Engine by using the ProcessEngines-class. This fails due to my process engine not beeing the static list of Process Engines which this class maintains and due to the property "initialized" being set to false. This makes the ProcessEngines-class try to create a new default process engine which fails due to a missing dataSource.

Cheers
Sebastian
5 REPLIES 5

trademak
Star Contributor
Star Contributor
Hi,

The Activiti Explorer and REST apps can be used as-is or you can choose the customise them.
When you choose for customisation your proposal of providing JARs with the classes is not a bad idea.
The resource files should not be part if this JAR I think, to prevent the problem you describe.

Best regards,

sebastian_s
Champ in-the-making
Champ in-the-making
Hello Tijs,

thanks for getting back on this. The second which should be taken into account that the process engine instance being used by the explorer should be configurable and should not depend on the ProcessEngines-classes.

Sebastian

sebastian_s
Champ in-the-making
Champ in-the-making
I created a JIRA issue to document this improvement proposal: http://jira.codehaus.org/browse/ACT-1112

Is the ticket closed ,  because i have a similar problem . please help me by suggesting the Process to do it.

Hi Akshay Burjwal‌ - Could you post a new question with the issue you are having? This post is quite old and some of the info may be out of date.