<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="https://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    JBPM 5.3 / Tomcat 7 / H2 / Demo
</h3>
<span style="margin-bottom: 10px;">
    modified by <a href="https://community.jboss.org/people/smclenahan">smclenahan</a> in <i>jBPM</i> - <a href="https://community.jboss.org/docs/DOC-18626">View the full document</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>&#160; The following details how to install jBPM 5.3 onto Tomcat 7, configured to run the provided 'Demo'.&#160; A <a class="jive-link-external-small" href="http://www.h2database.com/html/main.html">H2</a> database instance shall be used - which is reflected in the JTA / Hibernate configuration specified below.&#160; The following are assumed installed and relatively clean: </p><ul><li><a class="jive-link-external-small" href="http://tomcat.apache.org/download-70.cgi">Tomcat 7.0</a> (on port 8080)</li><li><a class="jive-link-external-small" href="http://ant.apache.org/">Ant 1.8.3</a></li><li><a class="jive-link-external-small" href="http://ant.apache.org/ivy/">Apache Ivy 2.0</a></li></ul><p><strong>NB:</strong> Tomcat should be stopped prior to installation.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>0: Download required software:</strong></p><p style="padding-left: 30px;"><a class="jive-link-external-small" href="http://www.jboss.org/jbpm">JBPM</a> : Select <a class="jive-link-external-small" href="http://sourceforge.net/projects/jbpm/files/">5.3.0 - Final Installer Full</a></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Once downloaded, unzip to a staging area separate from Tomcat - subsequent actions below will take place within the 'jbpm-install' folder.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>1: Pre-Installation Configuration of Tomcat: Prepare for J2EE</strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>It should be understood that Tomcat is not a J2EE application server - but rather a servlet container.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>However - Tomcat can be made to behave like a J2EE application server.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>In order to make this so, J2EE components need to be installed and configured on Tomcat.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>For JBPM this is an apriori requirement. The steps below shall add the following J2EE services to Tomcat: </p><ul><li>JTA (Java Transaction API)</li><li>Bitronix 2.1.3 Transaction Manager</li><li>JMS</li><li>JACC</li></ul><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p> <strong>a)</strong> In jbpm-install create folder: tomcat2j2ee&#160;&#160; \</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>b)</strong> In jbpm-install\tomcat2j2ee create the following files:&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>ivy.xml</strong></p><pre style="overflow: auto; width: 500px;"><code>&lt;ivy-module version="2.0"&gt;
&lt;info organisation="jbpm" module="btm" /&gt;
&lt;dependencies&gt;
&#160;&#160;&#160; &lt;dependency org="org.codehaus.btm" name="btm-dist" rev="2.1.3" /&gt;
&#160;&#160;&#160;&#160; &lt;dependency org="org.codehaus.btm" name="btm" rev="2.1.3"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;artifact name="btm" type="jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/dependency&gt;

&#160;&#160;&#160;&#160; &lt;dependency org="javax.transaction" name="jta" rev="1.1"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;artifact name="jta" type="jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/dependency&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;dependency org="org.apache.geronimo.specs" name="geronimo-jacc_1.1_spec" rev="1.0.2" &gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;artifact name="geronimo-jacc_1.1_spec" type="jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/dependency&gt;
&#160;&#160;&#160; &lt;/dependencies&gt;
&lt;/ivy-module&gt;
</code></pre><p> <strong>build.xml</strong></p><pre style="overflow: auto; width: 500px;"><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;

&lt;project xmlns:ivy="antlib:org.apache.ivy.ant" name="J2EE.install"&gt;

&#160; &lt;property name="install.home" value="./" /&gt;

&#160; &lt;property environment="env"/&gt;
&#160; &lt;property name="tomcat.home" value="${env.CATALINA_HOME}"/&gt;&#160; 
&#160; &lt;property name="tomcat.7.server.lib.dir" value="${tomcat.home}/lib" /&gt;

&#160; &lt;!-- ############ TOP LEVEL INSTALLATION ########### --&gt;
&#160; &lt;target name="install.j2ee.to.tomcat.7" depends="download.j2ee"&gt;
&#160;&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.lib.dir}/"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;fileset dir="${install.home}/lib" includes="*.jar" /&gt;
&#160;&#160;&#160; &lt;/copy&gt;
&#160; &lt;/target&gt;

&#160; &lt;target name="download.j2ee.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking J2EE Download..." /&gt;
&#160;&#160;&#160;&#160; &lt;condition property="btm.not.available"&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/btm-2.1.3.jar" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.j2ee" depends="download.j2ee.check" if="btm.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting J2EE..." /&gt;
&#160;&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160;&#160; &lt;ivy:retrieve /&gt;&#160; 
&#160; &lt;/target&gt;
&#160; 
&lt;/project&gt;
</code></pre><p> <strong>c)</strong> In jbpm-install\tomcat2j2ee execute: </p><pre style="overflow: auto; width: 500px;"><code>ant install.j2ee.to.tomcat.7
</code></pre><p> <strong>d)</strong> Create the following file in ${CATALINA_HOME}\conf&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>btm-config.properties</strong></p><pre style="overflow: auto; width: 500px;"><code>bitronix.tm.serverId=tomcat-btm-node0
bitronix.tm.journal.disk.logPart1Filename=${btm.root}/work/btm1.tlog
bitronix.tm.journal.disk.logPart2Filename=${btm.root}/work/btm2.tlog
bitronix.tm.resource.configuration=${btm.root}/conf/resources.properties
</code></pre><p><span style="font-size: 12px;"><strong>NB:</strong></span> The following option may also be of use for test / dev purposes:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>&#160;&#160;&#160;&#160;&#160; bitronix.tm.2pc.debugZeroResourceTransactions=true</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>e)</strong> Add the following parameters to $CATALINA_OPTS - such that they are passed to JVM when Tomcat starts: </p><pre style="overflow: auto; width: 500px;"><code>-Dbtm.root=${CATALINA_HOME}
-Dbitronix.tm.configuration=${CATALINA_HOME}/conf/btm-config.properties
</code></pre><p> NB: On windows do this through the configuration tool - do not set environment variable unless you understand the implications.&#160;&#160;&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>You will need to specify ${CATALINA_HOME} in full rather than using environment variable.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>You should now have a Tomcat 7 installation with J2EE services required for JBPM present.&#160; </strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>2: Installation JBPM 5.3 : Pre-Configuration</strong> </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>The installation process for JBPM 5.3 shall be presented in script form below.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Before that step though it is required to create and perform some initial configuration of both JBPM and Tomcat.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>a)</strong> Configuration of Tomcat&#160; </p><p><strong> i)</strong> Reconfigure ${CATALINA_HOME}/server.xml&#160;&#160;&#160;&#160;&#160; </p><p>&#160;&#160;&#160;&#160; Add following entries to ${CATALINA_HOME}/server.xml after the server entry for: org.apache.catalina.core.JreMemoryLeakPreventionListener </p><pre style="overflow: auto; width: 500px;"><code>&lt;Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener" /&gt;
&lt;Listener className="bitronix.tm.integration.tomcat55.BTMLifecycleListener" /&gt;
</code></pre><p> Add the following entries to the&#160; section: </p><pre style="overflow: auto; width: 500px;"><code>&lt;Resource name="jdbc/testDS1" uniqueName="jdbc/testDS1" auth="Container" removeAbandoned="true" factory="bitronix.tm.resource.ResourceObjectFactory" type="javax.sql.DataSource" /&gt;
&lt;Resource name="jta/UserTransaction" auth="Container" type="javax.transaction.UserTransaction" factory="bitronix.tm.BitronixUserTransactionObjectFactory" /&gt; 
&lt;Resource name="TransactionManager" auth="Container" type="javax.transaction.TransactionManager" factory="bitronix.tm.BitronixTransactionManagerObjectFactory" /&gt;
&lt;Resource name="TransactionSynchronizationRegistry" auth="Container" type="javax.transaction.TransactionSynchronizationRegistry" factory="bitronix.tm.BitronixTransactionSynchronizationRegistryObjectFactory" /&gt;
</code></pre><p><strong>ii)</strong> Reconfigure ${CATALINA_HOME}/context.xml&#160;&#160;&#160;&#160;&#160; </p><p>&#160;&#160; Add the following entries to context.xml after 'WatchedResource': </p><pre style="overflow: auto; width: 500px;"><code>&lt;Transaction factory="bitronix.tm.BitronixUserTransactionObjectFactory" /&gt;
&lt;!-- To make java:comp/env/testDS1 available for reports - via jdbc/testDS1 --&gt;
&lt;ResourceLink global="jdbc/testDS1" name="jdbc/testDS1" type="javax.sql.DataSource" /&gt; 
&lt;ResourceLink global="jta/UserTransaction" name="UserTransaction" type="javax.transaction.UserTransaction" /&gt;
</code></pre><p> NB: The Birt reporting by default will use Tomcat JNDI to look up resources.&#160; </p><p>&#160;&#160;&#160;&#160;&#160; The global resources defined in server.xml in terms of Bitronix JNDI are aliased to Tomcat's JNDI using resourcelink's above.&#160; </p><p>&#160;&#160;&#160;&#160;&#160; The hibernate configuration (below...) uses the Bitronix JNDI references&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>b)</strong> Configuration of JBPM&#160; </p><p>&#160; <strong>i)</strong> Create the following files in: jbpm-install\db&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>resources.properties</strong></p><pre style="overflow: auto; width: 500px;"><p><code>resource.ds1.className=bitronix.tm.resource.jdbc.lrc.LrcXADataSource
resource.ds1.uniqueName=jdbc/testDS1
resource.ds1.minPoolSize=0
resource.ds1.maxPoolSize=5
resource.ds1.driverProperties.driverClassName=org.h2.Driver
resource.ds1.driverProperties.url=jdbc:h2:tcp://localhost/~/test
resource.ds1.driverProperties.user=sa</code></p><p><code>resource.ds1.driverProperties.password=
resource.ds1.allowLocalTransactions=true
resource.ds1.testQuery=SELECT 1+1
</code></p></pre><p> <strong>persistence.xml</strong></p><pre style="overflow: auto; width: 500px;"><p><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&gt;
&lt;persistence
&#160;&#160;&#160; version="1.0"
&#160;&#160;&#160; xsi:schemaLocation=
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; "http://java.sun.com/xml/ns/persistence
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/orm 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/orm_1_0.xsd"
&#160;&#160;&#160; xmlns:orm="http://java.sun.com/xml/ns/persistence/orm"
&#160;&#160;&#160; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
&#160;&#160;&#160; xmlns="http://java.sun.com/xml/ns/persistence"&gt;

&#160;&#160;&#160;&#160; &lt;persistence-unit name="org.jbpm.persistence.jpa" transaction-type="JTA"&gt;
&#160;&#160;&#160; &lt;provider&gt;org.hibernate.ejb.HibernatePersistence&lt;/provider&gt;
&#160;&#160;&#160; &lt;jta-data-source&gt;java:comp/env/jdbc/testDS1&lt;/jta-data-source&gt;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;mapping-file&gt;META-INF/JBPMorm.xml&lt;/mapping-file&gt;
&#160;&#160;&#160; &lt;mapping-file&gt;META-INF/ProcessInstanceInfo.hbm.xml&lt;/mapping-file&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.persistence.processinstance.ProcessInstanceInfo&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.drools.persistence.info.WorkItemInfo&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.drools.persistence.info.SessionInfo&lt;/class&gt;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;class&gt;org.jbpm.process.audit.ProcessInstanceLog&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.process.audit.NodeInstanceLog&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.process.audit.VariableInstanceLog&lt;/class&gt;
&#160;&#160;&#160; &lt;properties&gt;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/&gt;
&#160;&#160;&#160; &lt;property name="hibernate.current_session_context_class" value="jta" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.transaction.fatory_class" value="org.hibernate.transaction.JTATransactionFactory" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.BTMTransactionManagerLookup" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.cache.provider_class" value="org.hibernate.cache.NoCacheProvider" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.cache.use_second_level_cache" value="false" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.max_fetch_depth" value="3"/&gt;
&#160;&#160;&#160; &lt;property name="hibernate.hbm2ddl.auto" value="update" /&gt;
&#160;&#160;&#160; &lt;property name="hibernate.show_sql" value="false" /&gt;
&#160;&#160; &lt;/properties&gt;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160; &lt;/persistence-unit&gt;
&lt;/persistence&gt;
</code></p></pre><p> <strong>persistence-human-task-service.xml</strong></p><pre style="overflow: auto; width: 500px;"><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&gt;
&lt;persistence version="1.0" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm_1_0.xsd"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns:orm="http://java.sun.com/xml/ns/persistence/orm"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns="http://java.sun.com/xml/ns/persistence"&gt;
&#160; &lt;persistence-unit name="org.jbpm.task"&gt;
&#160;&#160;&#160; &lt;provider&gt;org.hibernate.ejb.HibernatePersistence&lt;/provider&gt;
&#160;&#160;&#160; &lt;mapping-file&gt;META-INF/Taskorm.xml&lt;/mapping-file&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Attachment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Content&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.BooleanExpression&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Comment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Deadline&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Comment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Deadline&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Delegation&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Escalation&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Group&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.I18NText&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Notification&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.EmailNotification&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.EmailNotificationHeader&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.PeopleAssignments&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Reassignment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Status&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Task&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.TaskData&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.SubTasksStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.OnParentAbortAllSubTasksEndStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.OnAllSubTasksEndParentEndStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.User&lt;/class&gt;
&#160;&#160;&#160; &lt;properties&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.driver_class" value="org.h2.Driver"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.url" value="jdbc:h2:tcp://localhost/~/test" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.username" value="sa"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.password" value=""/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.autocommit" value="false" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.max_fetch_depth" value="3"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.hbm2ddl.auto" value="update" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.show_sql" value="false" /&gt;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.BTMTransactionManagerLookup" /&gt;
&#160;&#160;&#160; &lt;/properties&gt;
&#160; &lt;/persistence-unit&gt;
&lt;/persistence&gt;
</code></pre><p> <strong>persistence-human-task-war.xml</strong></p><pre style="overflow: auto; width: 500px;"><code>&lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&gt;
&lt;persistence version="1.0" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm_1_0.xsd"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns:orm="http://java.sun.com/xml/ns/persistence/orm"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; xmlns="http://java.sun.com/xml/ns/persistence"&gt;
&#160; &lt;persistence-unit name="org.jbpm.task"&gt;
&#160;&#160;&#160; &lt;provider&gt;org.hibernate.ejb.HibernatePersistence&lt;/provider&gt;
&#160;&#160;&#160; &lt;mapping-file&gt;META-INF/Taskorm.xml&lt;/mapping-file&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Attachment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Content&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.BooleanExpression&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Comment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Deadline&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Comment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Deadline&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Delegation&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Escalation&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Group&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.I18NText&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Notification&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.EmailNotification&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.EmailNotificationHeader&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.PeopleAssignments&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Reassignment&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Status&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.Task&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.TaskData&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.SubTasksStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.OnParentAbortAllSubTasksEndStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.OnAllSubTasksEndParentEndStrategy&lt;/class&gt;
&#160;&#160;&#160; &lt;class&gt;org.jbpm.task.User&lt;/class&gt;
&#160;&#160;&#160; &lt;properties&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.jndi.class" value="bitronix.tm.jndi.BitronixInitialContextFactory"/&gt;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.dialect" value="org.hibernate.dialect.H2Dialect"/&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.connection.datasource" value="jdbc/testDS1" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.max_fetch_depth" value="3"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.hbm2ddl.auto" value="update" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.show_sql" value="false" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;property name="hibernate.transaction.manager_lookup_class" value="org.hibernate.transaction.BTMTransactionManagerLookup" /&gt;
&#160;&#160;&#160; &lt;/properties&gt;
&#160; &lt;/persistence-unit&gt;
&lt;/persistence&gt;
</code></pre><p> <strong>NB:</strong> The above configurations will make use of H2 backend database - data sources are configured through JNDI using Bitronix as initial context.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>ii)</strong> Create the following file in: jbpm-install\conf </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>web.humantaskwar.xml</strong></p><pre style="overflow: auto; width: 500px; height: 300px;"><code>&lt;web-app&gt;
&#160; &lt;display-name&gt;Human Task Service WAR&lt;/display-name&gt;
&#160; &lt;servlet&gt;
&#160;&#160;&#160; &lt;servlet-name&gt;HumanTaskServiceServlet&lt;/servlet-name&gt;
&#160;&#160;&#160;&#160;&#160; &lt;servlet-class&gt;org.jbpm.task.servlet.HumanTaskServiceServlet&lt;/servlet-class&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- Following is a list of initialization parameters that HumanTaskService Servlet accepts
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; Main controller is active.config parameter that dictates what transport to initialize.
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; Then there are transport specific parameters that should be filled in only for selected
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; transport.
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; Last part provides access to configuring components of task Service itself. All of them
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; are optional and in case there are not set default values will apply.
&#160;&#160;&#160;&#160;&#160;&#160; --&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- active configuration on of hornetq|mina|jms (defauls to hornetq) --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;active.config&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;mina&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- Apache Mina configuration parameters --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;mina.host&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;localhost&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;mina.port&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;9123&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- HornetQ configuration parameters --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;hornetq.port&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- JMS configuration parameters --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;JMSTaskServer.connectionFactory&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;JMSTaskServer.transacted&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;JMSTaskServer.acknowledgeMode&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;JMSTaskServer.queueName&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;JMSTaskServer.responseQueueName&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;!-- Task Service configuration independent of transport --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;task.persistence.unit&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;org.jbpm.task&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- use org.jbpm.task.service.DefaultUserGroupCallbackImpl to configure sample user group callback for demo purpose--&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;user.group.callback.class&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;org.jbpm.task.service.DefaultUserGroupCallbackImpl&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;escalated.deadline.handler.class&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;user.info.class&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- allows to specify location of a files that will be used to initially populate task server db --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- accepts two types of files: MVEL and properties must be suffixed with .mvel and .properties --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- location of the files can be either on classpath (with prefix classpath:) or valid URL --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- NOTE: that with custom users files Administrator user must always be present!!! --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- use classpath:/org/jbpm/task/servlet/SampleUsers.mvel to configure sample users for demo purpose--&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- DefaultUsers.mvel is used to insert Administrator as it is required for task server to operate --&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;load.users&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;classpath:/org/jbpm/task/servlet/DefaultUsers.mvel&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; &lt;!-- use classpath:/org/jbpm/task/servlet/SampleGroups.mvel to configure sample users for demo purpose--&gt;
&#160;&#160;&#160;&#160;&#160; &lt;init-param&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-name&gt;load.groups&lt;/param-name&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param-value&gt;&lt;/param-value&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/init-param&gt;
&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;load-on-startup&gt;2&lt;/load-on-startup&gt;
&#160; &lt;/servlet&gt;
&#160; &lt;servlet-mapping&gt;
&#160;&#160;&#160; &lt;servlet-name&gt;HumanTaskServiceServlet&lt;/servlet-name&gt;
&#160;&#160;&#160; &lt;url-pattern&gt;/HumanTaskServiceServlet/*&lt;/url-pattern&gt;
&#160; &lt;/servlet-mapping&gt;
&lt;/web-app&gt;
</code></pre><p> <strong>Checkpoint: We have at this point installed required J2EE services to Tomcat, configured JNDI datasource components for JBPM on Tomcat and prepared a configuration of JBPM 5.3 to be installed. </strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>The next step is to perform the JBPM installation to Tomcat.</strong> </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>3: Installation JBPM 5.3</strong> </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>a)</strong> Add the following to the end of: jbpm-install\build.properties </p><pre style="overflow: auto; width: 500px;"><code># Tomcat Server Version
tomcat.server.version=7
# Database Parameters
# H2
h2.jdbc.driver.version=1.3.161
# Defines MySQL Connect JDBC Driver to Use
mysql.jdbc.driver.version=5.1.20
</code></pre><p> <strong>b)</strong> Create the following files in jbpm-install:&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>ivy.xml</strong></p><pre style="overflow: auto; width: 500px;"><code>&lt;ivy-module version="2.0"&gt;
&lt;info organisation="jbpm" module="btm" /&gt;
&lt;dependencies&gt;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;dependency org="javassist" name="javassist" rev="3.4.GA"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;artifact name="javassist" type="jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/dependency&gt;
&#160;&#160;&#160;&#160; &lt;dependency org="org.jboss.weld.servlet" name="weld-servlet" rev="1.1.8.Final"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;artifact name="weld-servlet" type="jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/dependency&gt;
&lt;/dependencies&gt;
&lt;/ivy-module&gt;
</code></pre><p> <strong>tomcat7build.xml</strong></p><pre style="overflow: auto; width: 500px; height: 400px;"><p><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;

&lt;project xmlns:ivy="antlib:org.apache.ivy.ant" name="jBPM.install"&gt;
&#160; &lt;property file="build.properties" /&gt;
&#160; &lt;property name="install.home" value="./" /&gt;
&#160; &lt;property environment="env"/&gt;
&#160; &lt;property name="tomcat.home" value="${env.CATALINA_HOME}"/&gt;&#160; 
&#160; &lt;property name="tomcat.7.server.conf.dir" value="${tomcat.home}/conf" /&gt;
&#160; &lt;property name="tomcat.7.server.lib.dir" value="${tomcat.home}/lib" /&gt;
&#160; &lt;property name="tomcat.7.server.deploy.dir" value="${tomcat.home}/webapps" /&gt;
&#160; &lt;property name="tomcat.bind.address" value="localhost" /&gt;
&#160; &lt;property name="h2.jdbc.jar" value="h2-${h2.jdbc.driver.version}.jar" /&gt;
&#160; &lt;property name="h2.download.url" value="http://repo1.maven.org/maven2/com/h2database/h2/${h2.jdbc.driver.version}/${h2.jdbc.jar}"/&gt;
&#160; &lt;property name="mysql.jdbc.jar" value="mysql-connector-java-${mysql.jdbc.driver.version}.jar" /&gt;
&#160; &lt;property name="mysql.download.url" value="http://repo1.maven.org/maven2/mysql/mysql-connector-java/${mysql.jdbc.driver.version}/${mysql.jdbc.jar}"/&gt;
&#160; &lt;property name="birt.version.as7" value="3_7_0"/&gt;&#160; 

&#160; &lt;property name="birt.download.url.as7" value="http://www.eclipse.org/downloads/download.php?file=/birt/downloads/drops/R-R1-3_7_0-201106151818/birt-runtime-3_7_0.zip&amp;amp;url=http://download.eclipse.org/birt/downloads/drops/R-R1-3_7_0-201106151818/birt-runtime-3_7_0.zip&amp;amp;mirror_id=1"/&gt;
&#160; 
&#160; &lt;!-- ############ TOP LEVEL INSTALLATION ########### --&gt;
&#160; &lt;target name="install.jbpmfull.to.tomcat.7"&gt;
&#160;&#160;&#160; &lt;antcall target="download.dependencies" /&gt;
&#160;&#160;&#160;&#160; &lt;antcall target="install.bitronix.config.into.tomcat.7" /&gt; 
&#160;&#160;&#160;&#160; &lt;antcall target="install.jBPM.into.tomcat.7" /&gt;
&#160;&#160;&#160;&#160; &lt;antcall target="install.guvnor.into.tomcat.7" /&gt;</code></p><p><code>&#160;&#160;&#160;&#160; &lt;antcall target="<code>install.designer.into.tomcat.7</code>" /&gt;</code></p><p><code>&#160;&#160;&#160;&#160; &lt;antcall target="install.form.builder.into.tomcat.7" /&gt;
&#160;&#160;&#160;&#160; &lt;antcall target="install.ht.war.into.tomcat.7" /&gt;&#160;&#160;&#160;&#160; 
&#160; &lt;/target&gt;

&#160; &lt;target name="start.demo"&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.jBPM.runtime" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="start.human.task" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;target name="install.jbpmfull.config.only.to.tomcat.7" &gt;
&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.bitronix.config.into.tomcat.7" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.gwtconsoleserver.config.into.tomcat.7" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.humantaskwar.config.into.tomcat.7" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- ############ TOMCAT SUPPORT ########### --&gt;&#160; 
&#160; 
&#160; &lt;target name="check.tomcat.version"&gt;
&#160;&#160;&#160; &lt;condition property="tomcat.version.is.7"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;equals arg1="${tomcat.server.version}" arg2="7" /&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
 
&#160; &lt;!-- ############ DOWNLOAD ############ --&gt;

&#160; &lt;!-- Dependencies --&gt;
&#160; &lt;target name="download.dependencies"&gt;
&#160;&#160;&#160; &lt;echo message="Getting Dependencies ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160;&#160; &lt;ivy:retrieve /&gt;&#160; 
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Databases --&gt;
&#160; &lt;!-- Download H2 --&gt;
&#160; &lt;target name="download.h2.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking H2 download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="h2.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/db/driver/${h2.jdbc.jar}" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.h2" depends="download.h2.check" if="h2.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting H2..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/db/driver"/&gt;
&#160;&#160;&#160; &lt;get src="${h2.download.url}" dest="${install.home}/db/driver/${h2.jdbc.jar}"&#160; /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Download MySQL --&gt;
&#160; &lt;target name="download.mysql.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking MySql download..." /&gt;
&#160;&#160;&#160; &lt;condition property="mysql.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/db/driver/${mysql.jdbc.jar}" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.mysql" depends="download.mysql.check" if="mysql.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting MySql ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/db/driver"/&gt;
&#160;&#160;&#160; &lt;get src="${mysql.download.url}" dest="${install.home}/db/driver/${mysql.jdbc.jar}"&#160; /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Download jBPM binaries --&gt;
&#160; &lt;target name="download.jBPM.bin.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking jBPM binaries download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="jBPM.bin.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/jbpm-${jBPM.version}-bin.zip" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.jBPM.bin" depends="download.jBPM.bin.check" if="jBPM.bin.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting jBPM binaries ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${jBPM.url}/jbpm-${jBPM.version}-bin.zip" dest="${install.home}/lib/jbpm-${jBPM.version}-bin.zip"&#160; /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Download Drools Guvnor --&gt;
&#160; &lt;target name="download.drools.guvnor.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking Drools Guvnor download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="drools.guvnor.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/guvnor-distribution-wars-${drools.guvnor.version}.war" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;&#160; 
&#160; &lt;target name="download.drools.guvnor" depends="download.drools.guvnor.check" if="drools.guvnor.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting Drools Guvnor ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${drools.guvnor.url}" dest="${install.home}/lib/guvnor-distribution-wars-${drools.guvnor.version}.war"/&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Download Designer --&gt;
&#160; &lt;target name="download.designer.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking Designer download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="designer.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/designer-${designer.version}.war" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;&#160; 
&#160; &lt;target name="download.designer" depends="download.designer.check" if="designer.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting Designer ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${designer.url}/designer-${designer.version}.war" dest="${install.home}/lib/designer-${designer.version}.war" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Download form builder --&gt;
&#160; &lt;target name="download.form.builder.check"&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;echo message="Checking Form Builder download ..." /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;condition property="form.builder.not.available"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/jbpm-${jBPM.version}-form-builder.war" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.form.builder" depends="download.form.builder.check" if="form.builder.not.available"&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;echo message="Getting Form Builder ..." /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;get src="${form.builder.url}" dest="${install.home}/lib/jbpm-${jBPM.version}-form-builder.war" /&gt;
&#160; &lt;/target&gt;&#160; 
&#160; 
&#160; &lt;!-- Download jBPM human task server war --&gt;
&#160; &lt;target name="download.jBPM.ht-war.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking jBPM human task war download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="jBPM.ht-war.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/jbpm-${jBPM.version}-human-task-war.zip" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.jBPM-ht.war" depends="download.jBPM.ht-war.check" if="jBPM.ht-war.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting jBPM human task war ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${jBPM.url}/jbpm-${jBPM.version}-human-task-war.zip" dest="${install.home}/lib/jbpm-${jBPM.version}-human-task-war.zip"&#160; /&gt;
&#160; &lt;/target&gt;&#160; 
&#160; 
&#160; &lt;!-- Download jBPM gwt-console --&gt;
&#160; &lt;target name="download.jBPM.gwt-console.check"&gt;
&#160;&#160;&#160; &lt;echo message="Checking jBPM gwt-console download ..." /&gt;
&#160;&#160;&#160; &lt;condition property="jBPM.gwt-console.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/jbpm-${jBPM.version}-gwt-console.zip" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.jBPM.gwt-console" depends="download.jBPM.gwt-console.check" if="jBPM.gwt-console.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting jBPM gwt-console ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${jBPM.url}/jbpm-${jBPM.version}-gwt-console.zip" dest="${install.home}/lib/jbpm-${jBPM.version}-gwt-console.zip"&#160; /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Download BIRT engine for AS7 --&gt;
&#160; &lt;target name="check.birt.as7"&gt;
&#160;&#160;&#160; &lt;condition property="birt.download"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;equals arg1="${jBPM.birt.download}" arg2="true" /&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.birt.check.as7" depends="check.birt.as7" if="birt.download"&gt;
&#160;&#160;&#160; &lt;echo message="Checking birt reporting engine download for as7 ..." /&gt;
&#160;&#160;&#160; &lt;condition property="birt.not.available"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;not&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;available file="${install.home}/lib/birt-runtime-${birt.version.as7}.zip" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/not&gt;
&#160;&#160;&#160; &lt;/condition&gt;
&#160; &lt;/target&gt;
&#160; &lt;target name="download.birt.as7" depends="download.birt.check.as7" if="birt.not.available"&gt;
&#160;&#160;&#160; &lt;echo message="Getting birt reporting engine for AS7 ..." /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/lib"/&gt;
&#160;&#160;&#160; &lt;get src="${birt.download.url.as7}" dest="${install.home}/lib/birt-runtime-${birt.version.as7}.zip" /&gt;
&#160; &lt;/target&gt;&#160; 
&#160; 
&#160; &lt;!-- ############ INSTALL ############ --&gt;

&#160; &lt;!-- Install Bitronix --&gt;
&#160; &lt;target name="install.bitronix.config.into.tomcat.7"&gt;
&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.conf.dir}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/resources.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160; &lt;/target&gt;<br/></code></p><p><code> </code></p><code style="font-family: 'Droid Sans Mono', monospace !important; color: #333333;"><p>&#160; &lt;!-- Install gtw-console-server config --&gt;</p><p>&#160; &lt;target name="install.gwtconsoleserver.config.into.tomcat.7"&gt;</p><p>&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.deploy.dir}/gwt-console-server/WEB-INF/classes"</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/hibernate.cfg.xml"</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;</p><p>&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.deploy.dir}/gwt-console-server/WEB-INF/classes/META-INF"</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/persistence.xml"</p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;</p><p>&#160; &lt;/target&gt; </p></code><p><code><br/></code></p><p><code> </code></p><code style="font-family: 'Droid Sans Mono', monospace !important; color: #333333;"><p>&#160; &lt;!-- Install human-task-war config --&gt;</p><p>&#160; &lt;target name="install.humantaskwar.config.into.tomcat.7"&gt; </p><p>&#160;&#160;&#160; &lt;copy file="${install.home}/conf/web.humantaskwar.xml" </p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/jbpm-human-task-war/WEB-INF/web.xml" </p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;</p><p>&#160;&#160;&#160; &lt;copy file="${install.home}/db/persistence-human-task-war.xml" </p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/jbpm-human-task-war/WEB-INF/classes/persistence.xml" </p><p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;</p><p>&#160; &lt;/target&gt;&#160; </p></code><p><code> </code></p><p><code> </code></p><p><code>&#160; &lt;!-- Install JDBC --&gt;
&#160; &lt;target name="install.h2.into.tomcat.7" depends="download.h2,check.tomcat.version"&gt;
&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.lib.dir}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/driver/${h2.jdbc.jar}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;target name="install.mysql.into.tomcat.7" depends="download.mysql,check.tomcat.version"&gt;
&#160;&#160;&#160; &lt;copy todir="${tomcat.7.server.lib.dir}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/driver/${mysql.jdbc.jar}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;&#160; 
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Install guvnor --&gt;
&#160; &lt;target name="install.guvnor.into.tomcat.7" depends="download.drools.guvnor,check.tomcat.version"&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target"/&gt;
&#160;&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-drools-guvnor-war"/&gt;

&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/guvnor-distribution-wars-${drools.guvnor.version}.war" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${install.home}/target/jbpm-drools-guvnor-war" /&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;!-- Fixes for Tomcat... --&gt;
&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-drools-guvnor-war/WEB-INF/lib/servlet-api-2.5.jar"/&gt;

&#160;&#160;&#160; &lt;copy file="${install.home}/lib/weld-servlet-1.1.8.Final.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-drools-guvnor-war/WEB-INF/lib/weld-servlet-1.1.8.Final.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="removeJavaxServletFromJar" &gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param name="jarpath" value="${install.home}/target/jbpm-drools-guvnor-war/WEB-INF/lib" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param name="jarname" value="jboss-servlet-api_3.0_spec-1.0.0.Final.jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/antcall&gt;

&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="removeJavaxServletFromJar" &gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param name="jarpath" value="${install.home}/target/jbpm-drools-guvnor-war/WEB-INF/lib" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;param name="jarname" value="gwt-user-2.3.0.jar" /&gt;
&#160;&#160;&#160;&#160; &lt;/antcall&gt;

&#160;&#160;&#160; &lt;zip basedir="${install.home}/target/jbpm-drools-guvnor-war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${install.home}/target/guvnor-distribution-wars-${drools.guvnor.version}.war" /&gt;

&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/target/guvnor-distribution-wars-${drools.guvnor.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/drools-guvnor.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;delete dir="${install.home}/target"/&gt; 

&#160; &lt;/target&gt;&#160;&#160;&#160;&#160;&#160;&#160; 

&#160; &lt;target name="removeJavaxServletFromJar"&gt;
&#160;&#160;&#160; &lt;mkdir dir="${jarpath}/${jarname}.tmp" /&gt;
&#160;&#160;&#160; &lt;unzip src="${jarpath}/${jarname}"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${jarpath}/${jarname}.tmp" /&gt;
&#160;&#160;&#160;&#160; &lt;move file="${jarpath}/${jarname}" toFile="${jarpath}/${jarname}.orig" /&gt;
&#160;&#160;&#160; &lt;delete dir="${jarpath}/${jarname}.tmp/javax/servlet" /&gt;
&#160;&#160;&#160; &lt;zip basedir="${jarpath}/${jarname}.tmp"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${jarpath}/${jarname}" /&gt;
&#160;&#160;&#160; &lt;delete dir="${jarpath}/${jarname}.tmp" /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Install designer --&gt;
&#160; &lt;target name="install.designer.into.tomcat.7" depends="download.designer,check.tomcat.version"&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/lib/designer-${designer.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/designer.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Install form builder --&gt;
&#160; &lt;target name="install.form.builder.into.tomcat.7" depends="download.form.builder"&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target"/&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-form-builder-war"/&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/jbpm-${jBPM.version}-form-builder.war" dest="${install.home}/target/jbpm-form-builder-war" /&gt;

&#160;&#160;&#160; &lt;copy file="${install.home}/auth/users.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-form-builder-war/WEB-INF/classes/users.properties" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/auth/roles.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-form-builder-war/WEB-INF/classes/roles.properties" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/auth/users.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${jboss.server.conf.dir}/users.properties" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/auth/roles.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${jboss.server.conf.dir}/roles.properties" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;zip basedir="${install.home}/target/jbpm-form-builder-war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${install.home}/target/jbpm-${jBPM.version}-form-builder.war" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;copy file="${install.home}/target/jbpm-${jBPM.version}-form-builder.war" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/jbpm-form-builder.war" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;delete dir="${install.home}/target" /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Install jbpm human task war --&gt;
&#160; &lt;target name="install.ht.war.into.tomcat.7" depends="download.jBPM-ht.war"&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/jbpm-${jBPM.version}-human-task-war.zip" dest="${install.home}/lib" /&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target"/&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-human-task-war"/&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/jbpm-human-task-war-${jBPM.version}.war" dest="${install.home}/target/jbpm-human-task-war" /&gt;

&#160;&#160;&#160;&#160; &lt;!-- Abstraction for Tomcat Install --&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/conf/web.humantaskwar.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/task-service/resources/war/web.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/db/persistence-human-task-war.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/task-service/resources/war/persistence.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160; &lt;!-- Now Proceed To patch the WAR... --&gt;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/task-service/resources/war/web.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-human-task-war/WEB-INF/web.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/task-service/resources/war/persistence.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-human-task-war/WEB-INF/classes/META-INF/persistence.xml" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/jbpm-tm.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-human-task-war/WEB-INF/lib/jbpm-tm.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160; &lt;!-- Fix for Tomcat --&gt;
&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-human-task-war/WEB-INF/lib/jta-1.1.jar"/&gt;
&#160;&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-human-task-war/WEB-INF/lib/javassist-3.14.0-GA.jar" /&gt;

&#160;&#160;&#160;&#160; &lt;copy todir="${install.home}/target/jbpm-human-task-war/WEB-INF/lib/"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/lib/javassist-3.4.GA.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;

&#160;&#160;&#160;&#160; &lt;!-- Rebuild the WAR and deploy --&gt;
&#160;&#160;&#160; &lt;zip basedir="${install.home}/target/jbpm-human-task-war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${install.home}/target/jbpm-${jBPM.version}-human-task-war.war" /&gt;

&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/target/jbpm-${jBPM.version}-human-task-war.war" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/jbpm-human-task-war.war" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;delete dir="${install.home}/target" /&gt; 
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Install gwt-console --&gt;
&#160; &lt;target name="install.jBPM.into.tomcat.7" depends="download.mysql,download.h2,download.jBPM.gwt-console" &gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.mysql.into.tomcat.7" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160; &lt;antcall target="install.h2.into.tomcat.7" /&gt;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/target"/&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/jbpm-${jBPM.version}-gwt-console.zip" 
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${install.home}/target/" /&gt;
&#160;&#160;&#160; &lt;antcall target="install.jBPM-gwt-console.into.tomcat.7" /&gt; 
&#160;&#160;&#160; &lt;antcall target="install.jBPM-gwt-console-server.into.tomcat.7" /&gt;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;delete dir="${install.home}/target"/&gt; 
&#160; &lt;/target&gt;
&#160;&#160;&#160; 
&#160; &lt;target name="install.jBPM-gwt-console.into.tomcat.7" depends="check.tomcat.version" if="tomcat.version.is.7"&gt;
&#160;&#160;&#160; &lt;!-- gwt-console --&gt;
&#160;&#160;&#160;&#160; &lt;unzip src="${install.home}/target/jbpm-gwt-console-${jBPM.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${install.home}/target/jbpm-gwt-console-war"/&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;!-- Tomcat Fix --&gt;
&#160;&#160;&#160;&#160; &lt;copy todir="${install.home}/target/jbpm-gwt-console-war/WEB-INF/lib"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/lib/javassist-3.4.GA.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;!-- Repackage WAR and deploy --&gt;
&#160;&#160;&#160;&#160; &lt;zip basedir="${install.home}/target/jbpm-gwt-console-war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${install.home}/target/jbpm-gwt-console-${jBPM.version}.war"/&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;copy file="${install.home}/target/jbpm-gwt-console-${jBPM.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/jbpm-gwt-console.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Install gwt-console-server --&gt;
&#160; &lt;target name="install.jBPM-gwt-console-server.into.tomcat.7" depends="check.tomcat.version" if="tomcat.version.is.7"&gt;
&#160;&#160;&#160; &lt;!-- reporting --&gt;
&#160;&#160;&#160; &lt;antcall target="download.birt.as7" /&gt;&#160; 
&#160;&#160;&#160; &lt;!-- gwt-console-server --&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/target/jbpm-gwt-console-server-${jBPM.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${install.home}/target/jbpm-gwt-console-server-war"/&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/db/persistence.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/classes/META-INF/persistence.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/db/ProcessInstanceInfo.hbm.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/classes/META-INF/ProcessInstanceInfo.hbm.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/auth/users.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/classes/users.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/auth/roles.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/classes/roles.properties"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy file="${install.home}/jbpm-tm.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib/jbpm-tm.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;

&#160;&#160;&#160; &lt;!-- Fix for conflicting javassist jar --&gt;
&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib/javassist-3.6.0.GA.jar"/&gt;
&#160;&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib/javassist-3.14.0-GA.jar" /&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;copy todir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/lib/javassist-3.4.GA.jar"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160;&#160; &lt;!-- Further fixes for Tomcat... --&gt;
&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib/el-api-1.2.jar"/&gt;
&#160;&#160;&#160; &lt;delete file="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib/dom4j-1.6.jar"/&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;!-- Other configuration like work item handlers --&gt;
&#160;&#160;&#160;&#160; &lt;!--
&#160;&#160;&#160; &lt;copy todir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/classes" overwrite="true"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;fileset dir="${install.home}/conf"/&gt;
&#160;&#160;&#160; &lt;/copy&gt;
&#160;&#160;&#160;&#160; --&gt;
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;!-- reporting --&gt;
&#160;&#160;&#160; &lt;antcall target="install.reporting.into.tomcat.7" /&gt; 
&#160;&#160;&#160;&#160; 
&#160;&#160;&#160; &lt;zip basedir="${install.home}/target/jbpm-gwt-console-server-war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; destfile="${install.home}/target/jbpm-gwt-console-server-${jBPM.version}.war"/&gt;

&#160;&#160;&#160;&#160; &lt;copy file="${install.home}/target/jbpm-gwt-console-server-${jBPM.version}.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${tomcat.7.server.deploy.dir}/gwt-console-server.war"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160; &lt;/target&gt;
&#160; 
&#160; &lt;!-- Install reporting Tomcat7&#160; --&gt;
&#160; &lt;target name="install.reporting.into.tomcat.7" depends="check.birt.as7" if="birt.download" &gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/birt"/&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/birt-runtime-${birt.version.as7}.zip"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; dest="${install.home}/birt"/&gt;
&#160;&#160;&#160; &lt;copy todir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/lib"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;fileset dir="${install.home}/birt/birt-runtime-${birt.version.as7}/ReportEngine/lib"&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;include name="**/*.jar"/&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/fileset&gt;
&#160;&#160; &lt;/copy&gt;
&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/output"/&gt;
&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/output/image"/&gt;&#160;&#160; 
&#160;&#160; &lt;mkdir dir="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/reports"/&gt;
&#160;&#160; &lt;copy file="${install.home}/report/${birt.version.as7}/overall_activity.rptdesign"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; tofile="${install.home}/target/jbpm-gwt-console-server-war/WEB-INF/reports/overall_activity.rptdesign"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true"/&gt;
&#160;&#160; &lt;delete dir="${install.home}/birt"/&gt;
&#160; &lt;/target&gt;

&#160; &lt;!-- Install Demo --&gt;

&#160; &lt;!-- create runtime --&gt;
&#160; &lt;target name="install.jBPM.runtime" depends="download.jBPM.bin"&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/runtime"/&gt;
&#160;&#160;&#160; &lt;unzip src="${install.home}/lib/jbpm-${jBPM.version}-bin.zip" dest="${install.home}/runtime" /&gt;
&#160; &lt;/target&gt;

&#160; &lt;path id="classpath.human.task"&gt;
&#160;&#160;&#160; &lt;fileset dir="${install.home}/runtime" includes="**/*.jar"/&gt;
&#160;&#160;&#160; &lt;fileset dir="${install.home}/db/driver" includes="**/*.jar"/&gt;
&#160; &lt;/path&gt;
&#160; &lt;target name="start.human.task"&gt;
&#160;&#160;&#160; &lt;mkdir dir="${install.home}/task-service/target"/&gt;
&#160;&#160;&#160; &lt;javac includeantruntime="false" srcdir="${install.home}/task-service/src" destdir="${install.home}/task-service/target" classpathref="classpath.human.task"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;compilerarg value="-Xlint:unchecked"/&gt;
&#160;&#160;&#160; &lt;/javac&gt;
&#160;&#160;&#160; &lt;copy tofile="${install.home}/task-service/resources/META-INF/persistence.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; file="${install.home}/db/persistence-human-task-service.xml"
&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; overwrite="true" /&gt;
&#160;&#160;&#160; &lt;copy todir="${install.home}/task-service/target"&gt;
&#160;&#160;&#160;&#160;&#160; &lt;fileset dir="${install.home}/task-service/resources"/&gt;
&#160;&#160;&#160; &lt;/copy&gt;
&#160;&#160;&#160; &lt;java classname="org.jbpm.DemoTaskService" fork="true"&gt;&#160; 
&#160;&#160;&#160;&#160;&#160; &lt;classpath&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;pathelement path="${install.home}/task-service/target"/&gt;
&#160;&#160;&#160;&#160;&#160;&#160;&#160; &lt;path refid="classpath.human.task" /&gt;
&#160;&#160;&#160;&#160;&#160; &lt;/classpath&gt;
&#160;&#160;&#160; &lt;/java&gt;
&#160; &lt;/target&gt;
&lt;/project&gt;
</code></p></pre><p> <strong>c)</strong> Perform the installation: In jbpm-install execute: </p><pre style="overflow: auto; width: 500px;"><code>ant -buildfile tomcat7build.xml install.jbpmfull.to.tomcat.7
</code></pre><p> <strong>d)</strong> Add the following parameters to $CATALINA_OPTS and passed to JVM when Tomcat started: </p><pre style="overflow: auto; width: 500px;"><code>-Xms256m
-Xmx1024m
-XX:PermSize=128m
-XX:MaxPermSize=256m
-Dreporting.needcontext=true
</code></pre><p> <strong>NB:</strong> On windows do this through the configuration tool - do not set environment variable unless you understand the implications.&#160; </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong><span>Checkpoint: We have at this point installed JBPM 5.3 to Tomcat. </span></strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong><span>Before proceeding to run the 'demo' below it should be noted that there is an error in the 5.3 FINAL distribution which prevents the console from running whilst drools-guvnor is running. In order to see the demo cleanly - stop drools-guvnor.&#160; </span></strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong><span>In the above configuration - reporting will work - however - see here for implications of moving away from H2 backend, and </span><a class="jive-link-external-small" href="http://ironclaws.wordpress.com/2012/06/23/jbpm-reporting-birt-tomcat-7-pure-jndi-without-tomcat-correction-2/" target="_blank">here</a> if you want to configure the report engines initial JNDI context. </strong></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>4: Running the Demo</strong> </p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>a)</strong> Update report definition: ${CATALINA_HOME}/webapps/gwt-console-server/WEB-INF/reports/overall_activity.rptdesign&#160;&#160;&#160;&#160;&#160; </p><p>&#160;&#160; Add following to 'oda-data-source' section: </p><pre style="overflow: auto; width: 500px;"><code>&lt;property name="odaJndiName"&gt;java:comp/env/jdbc/testDS1&lt;/property&gt;</code></pre><p> <strong>b)</strong> Add following to Tomcat startup parameter: </p><pre style="overflow: auto; width: 500px;"><code>-Djbpm.console.directory=&lt;path-to-jbpm-install&gt;\sample\evaluation\src\main\resources
</code></pre><p> <strong>c)</strong> Reconfigure ${CATALINA_HOME}/tomcat-users.xml, add: </p><pre style="overflow: auto; width: 500px;"><code>&lt;role rolename="manager" /&gt;
&lt;role rolename="admin" /&gt;
&lt;role rolename="user" /&gt;
&lt;role rolename="PM" /&gt;
&lt;role rolename="HR" /&gt;
&lt;role rolename="webdesigner" /&gt;
&lt;role rolename="functionalanalyst" /&gt;
&lt;role rolename="sales" /&gt;
&lt;user username="krisv" password="krisv" roles="manager,admin,user" /&gt;
&lt;user username="john" password="john" roles="admin,manager,user,PM" /&gt;
&lt;user username="mary" password="mary" roles="admin,manager,user,HR" /&gt;
&lt;user username="sales-rep" password="sales-rep" roles="admin,manager,user,sales" /&gt;
&lt;user username="admin" password="admin" roles="admin,manager,user,webdesigner,functionalanalyst" /&gt;
</code></pre><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><strong>e)</strong> Start H2: In jbpm-install execute:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><pre style="overflow: auto; width: 500px;"><code>ant start.h2</code></pre><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><span><strong>f)</strong> Start Tomcat&#160; </span></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><span><strong>g)</strong> Stop drools-guvnor and restart gwt-console-server (to be on the safe side)&#160;&#160;&#160;&#160;&#160; </span></p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p><span><strong>h)</strong> Naviate to: </span><a class="jive-link-external-small" href="http://localhost:8080/jbpm-gwt-console" target="_blank">http://localhost:8080/jbpm-gwt-console</a></p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Comment by <a href="https://community.jboss.org/docs/DOC-18626">going to Community</a></p>

        <p style="margin: 0;">Create a new document in jBPM at <a href="https://community.jboss.org/choose-container!input.jspa?contentType=102&containerType=14&container=2034">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>