Saturday, December 17, 2016

Activiti 5.22 Introduction and Installation

Tuesday, April 26, 2016

Activiti BPMN Configure Oracle Database

I use version 5.19 of Activiti BPMN Engine.

Activiti comes with an in-memory H2 database. Which is not useful for any serious development or for Production Purposes. So i installed an Oracle 12c on my local computer for educational purposes and Configured Activiti to start pointing to that Database.

here's what you need to do to configure Oracle database for Activiti 5.19

I Assume you copied activiti war's into your Tomcat webapps folder. Once you have copied the wars will explode into a folder. I have copied both the activiti-explorer.war and activiti-rest.war to my tomcat8\webapps folder and started up tomcat.

After this you can go to tomcat8\webapps\activiti-explorer\WEB-INF\classes and you find a file called db.properties there. You can delete the contents of this file and replace it with

db = oracle
jdbc.driver = oracle.jdbc.OracleDriver
jdbc.url = jdbc:oracle:thin:@localhost:1521:SUNIL
jdbc.username = user
jdbc.password = password

and update your DB details in this.

You also need to add your ojdbc.jar to this lib folder here - tomcat8\webapps\activiti-explorer\WEB-INF\lib

You need to follow same steps for activiti-rest also.

If you are configuring Activiti into this Oracle DB, then you need to run some scripts to create your tables and other DDL in Oracle.

For this you can log into your Oracle user and run the script from your actual Activiti download folder. \activiti-5.19.0.2\database\create
For Oracle you need to execute the below .sql files in your oracle user.

activiti.oracle.create.engine.sql
activiti.oracle.create.history.sql
activiti.oracle.create.identity.sql

Now you can login to http://localhost:8090/activiti-explorer/ to log in and you database will be connecting to Oracle.

Thanks
SunilTK