This content has been marked as final.
Show 4 replies
-
1. Re: jBPM 5.1 with Spring mvc
sameer82 Jul 1, 2011 4:16 PM (in response to sameer82)It will be really great if jBPM Team could provide a sample Spring mvc integrated example. This is really missing here.
-
2. Re: jBPM 5.1 with Spring mvc
bpmn2user Jul 4, 2011 10:13 AM (in response to sameer82)jBPM is agnostic to any UI framework you want to use, i.e, it does not matter if you use Spring MVC, Struts, JSF, Swing, GWT etc. You can use jBPM API from any framework you like.
Here are some examples to see how the jBPM API is used. You can have the API calls from your Spring MVC framework.
-
3. Re: jBPM 5.1 with Spring mvc
trh3037 Jul 12, 2011 6:49 AM (in response to bpmn2user)I found that using the spring to manage the transaction for jbpm5 ,what seems to be incorrect.
here is my code:
persistent.xml: <persistence-unit name="org.jbpm.persistence.jpa" transaction-type="RESOURCE_LOCAL"> code : EntityManagerFactory emf = (EntityManagerFactory) Constants.ctx.getBean("entityManagerFactory"); Environment env = KnowledgeBaseFactory.newEnvironment(); env.set(EnvironmentName.ENTITY_MANAGER_FACTORY, emf); env.set(EnvironmentName.TRANSACTION_MANAGER, Constants.ctx.getBean("txManager")); StatefulKnowledgeSession session = JPAKnowledgeService.newStatefulKnowledgeSession(kbase, config, env); applicationContext.xml: <context:annotation-config /> <bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"> <property name="driverClassName" value="oracle.jdbc.OracleDriver" /> <property name="url" value="jdbc:oracle:thin:@localhost:1521:orcl" /> <property name="username" value="jbpm" /> <property name="password" value="jbpm" /> </bean> <bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"> <property name="persistenceUnitName" value="org.jbpm.persistence.jpa"></property> <property name="dataSource" ref="dataSource"></property> <property name="jpaVendorAdapter"> <bean class="org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter"> <property name="database" value="ORACLE" /> <property name="showSql" value="true" /> </bean> </property> </bean> <bean id="txManager" class="org.springframework.orm.jpa.JpaTransactionManager"> <property name="entityManagerFactory" ref="entityManagerFactory" /> </bean> <tx:annotation-driven transaction-manager="txManager" />
The result is i can't start the second task.
You can use the following link to view details:
-
4. Re: jBPM 5.1 with Spring mvc
trh3037 Jul 13, 2011 10:30 PM (in response to trh3037)Does anyone can solve the problem?