12-14-2012 06:14 AM
<property name="customPostBPMNParseListeners">
<list>
<bean class="org.handler.ParseListener"></bean>
</list>
</property>
01-09-2013 05:05 PM
01-10-2013 05:33 AM
public void parseServiceTask(Element serviceTaskElement, ScopeImpl scope, ActivityImpl activity) {addActivityHandlers(activity);
}
addActivityHandlers(ActivityImpl activity) {
activity.addExecutionListener(PvmEvent.EVENTNAME_START, ACTIVITY_INSTANCE_START_LISTENER, 0);
activity.addExecutionListener(PvmEvent.EVENTNAME_END, ACTIVITY_INSTANCE_END_LISTENER);
}
01-10-2013 05:45 AM
01-10-2013 05:58 AM
<context:annotation-config />
<bean id="dbProperties" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location" value="classpath:db.properties" />
<!– Allow other PropertyPlaceholderConfigurer to run as well –>
<property name="ignoreUnresolvablePlaceholders" value="true"/>
</bean>
<bean id="demoDataGenerator" class="org.activiti.explorer.demo.DemoDataGenerator">
<property name="processEngine" ref="processEngine" />
</bean>
<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource">
<property name="driverClassName" value="${jdbc.driver}" />
<property name="url" value="${jdbc.url}" />
<property name="username" value="${jdbc.username}" />
<property name="password" value="${jdbc.password}" />
<property name="defaultAutoCommit" value="false" />
</bean>
<!– <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource">
<property name="driverClassName" value="com.mysql.jdbc.Driver" />
<property name="url" value="jdbc:mysql://localhost:3306/activiti?autoReconnect=true" />
<property name="username" value="activiti" />
<property name="password" value="activiti" />
<property name="defaultAutoCommit" value="false" />
</bean> –>
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource" />
</bean>
<bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
<property name="dataSource" ref="dataSource" />
<property name="transactionManager" ref="transactionManager" />
<property name="databaseSchemaUpdate" value="true" />
<property name="jobExecutorActivate" value="true" />
<property name="customFormTypes">
<list>
<ref bean="userFormType"/>
</list>
</property>
<!– My Listener –>
<property name="customPostBPMNParseListeners">
<list>
<bean class="org.bpmnwithactiviti.handler.ParseListener"></bean>
</list>
</property>
</bean>
<bean id="processEngine" class="org.activiti.spring.ProcessEngineFactoryBean" destroy-method="destroy">
<property name="processEngineConfiguration" ref="processEngineConfiguration" />
</bean>
<bean id="repositoryService" factory-bean="processEngine" factory-method="getRepositoryService" />
<bean id="runtimeService" factory-bean="processEngine" factory-method="getRuntimeService" />
<bean id="taskService" factory-bean="processEngine" factory-method="getTaskService" />
<bean id="historyService" factory-bean="processEngine" factory-method="getHistoryService" />
<bean id="managementService" factory-bean="processEngine" factory-method="getManagementService" />
<bean id="identityService" factory-bean="processEngine" factory-method="getIdentityService" />
<bean id="activitiLoginHandler" class="org.activiti.explorer.ui.login.DefaultLoginHandler">
<property name="identityService" ref="identityService" />
</bean>
<!– Include the UI-related wiring. This UI context will be used in the alfresco activiti admin UI –>
<import resource="activiti-ui-context.xml" />
<!– Custom form types –>
<bean id="userFormType" class="org.activiti.explorer.form.UserFormType"/>
</beans>
01-10-2013 07:43 AM
01-10-2013 08:06 AM
<bean id="dataSource"
class="org.springframework.jdbc.datasource.TransactionAwareDataSourceProxy">
<property name="targetDataSource">
<bean class="org.springframework.jdbc.datasource.SimpleDriverDataSource">
<property name="driverClass" value="org.h2.Driver" />
<property name="url" value="jdbc:h2:mem:activiti;DB_CLOSE_DELAY=1000" />
<property name="username" value="sa" />
<property name="password" value="" />
</bean>
</property>
</bean>
<bean id="transactionManager"
class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource" />
</bean>
<bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
<property name="databaseType" value="h2" />
<property name="dataSource" ref="dataSource" />
<property name="transactionManager" ref="transactionManager" />
<property name="databaseSchemaUpdate" value="true" />
<!– Deploy BPMN process –>
<property name="deploymentResources"
value="classpath*:listener/processEventListener.bpmn20.xml" />
<property name="history" value="full" />
<property name="jobExecutorActivate" value="false" />
<!– My Listener –>
<property name="customPostBPMNParseListeners">
<list>
<bean class="org.bpmnwithactiviti.handler.ParseListener"></bean>
</list>
</property>
</bean>
<bean id="processEngine" class="org.activiti.spring.ProcessEngineFactoryBean">
<property name="processEngineConfiguration" ref="processEngineConfiguration" />
</bean>
<bean id="repositoryService" factory-bean="processEngine"
factory-method="getRepositoryService" />
<bean id="runtimeService" factory-bean="processEngine"
factory-method="getRuntimeService" />
<bean id="taskService" factory-bean="processEngine"
factory-method="getTaskService" />
<bean id="historyService" factory-bean="processEngine"
factory-method="getHistoryService" />
<bean id="managementService" factory-bean="processEngine"
factory-method="getManagementService" />
</beans>
01-10-2013 09:35 AM
01-10-2013 10:05 AM
01-10-2013 10:10 AM
01-10-2013 10:26 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.