SSH和jbpm4.3整合问题,大家帮我看下!谢谢了!
ssh和jbpm 整合代码如下:
<bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSource"/>
<property name="mappingDirectoryLocations">
<list>
<value>classpath:jbpm.repository.hbm.xml</value>
<value>classpath:jbpm.execution.hbm.xml</value>
<value>classpath:jbpm.history.hbm.xml</value>
<value>classpath:jbpm.task.hbm.xml</value>
<value>classpath:jbpm.identity.hbm.xml</value>
</list>
</property>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">${hibernate.dialect}</prop>
<prop key="hibernate.show_sql">${hibernate.show_sql}</prop>
<prop key="hibernate.jdbc.fetch_size">${hibernate.jdbc.fetch_size}</prop>
<prop key="hibernate.jdbc.batch_size">${hibernate.jdbc.batch_size}</prop>
<prop key="hibernate.use_outer_join">true</prop>
<prop key="hibernate.cache.use_query_cache">true</prop>
<prop key="hibernate.cache.use_second_level_cache">true</prop>
<prop key="hibernate.cache.provider_class">org.hibernate.cache.EhCacheProvider</prop>
<prop key="hibernate.hbm2ddl.auto">${hibernate.hbm2ddl.auto}</prop>
</props>
</property>
</bean>
<bean id="springHelper" class="org.jbpm.pvm.internal.processengine.SpringHelper" />
<bean id="processEngine" factory-bean="springHelper" factory-method="createProcessEngine" />
<bean id="jbpmTemplate" class="com.sitech.channel.core.jbpm.JbpmTemplate">
<property name="processEngine" ref="processEngine"></property>
</bean>
错误信息主要是找不到jbpm.repository.hbm.xml 等几个映射用xml文件,
我只导入了一个jbpm.jar包,包我解压,发现里面有这几个文件。
不知道什么原因,请大家帮忙看看。
[解决办法]
<property name="mappingLocations">
<list>
<value>classpath:jbpm.repository.hbm.xml</value>
<value>classpath:jbpm.execution.hbm.xml</value>
<value>classpath:jbpm.history.hbm.xml</value>
<value>classpath:jbpm.task.hbm.xml</value>
<value>classpath:jbpm.identity.hbm.xml</value>
</list>
</property>
把jbpm.cfg.xml放到src下
[解决办法]
你把jbpm4.3下的lib拷入工程lib下
jbpm.cfg.xml:
<jbpm-configuration>
<import resource="jbpm.default.cfg.xml" />
<import resource="jbpm.tx.spring.cfg.xml" />
<import resource="jbpm.jpdl.cfg.xml" />
<import resource="jbpm.bpmn.cfg.xml" />
<import resource="jbpm.identity.cfg.xml" />
<import resource="jbpm.businesscalendar.cfg.xml" />
<import resource="jbpm.console.cfg.xml" />
<!-- <import resource="jbpm.jobexecutor.cfg.xml" />-->
</jbpm-configuration>