首页 / 软件开发 / JAVA / JBPM4 4.0使用问题 -- 1:结合Sqlserver使用问题
JBPM4 4.0使用问题 -- 1:结合Sqlserver使用问题2010-12-26 BlogJava Kim惊叹JBPM的更新速度项目要使用工作流引擎谈需求时JBPM 4.0还是beta版,现在我们需求谈好,JBPM 4.0也已经出到GA版JBPM 4与3的差别相当大......,看来JBPM自己已经抛弃了3,我们项目也没必要犹豫了,选4吧~下载地址:http://downloads.sourceforge.net/project/jbpm/a%29%20jBPM%204/jbpm-4.0/jbpm-4.0.zip?use_mirror=nchc1:JBPM 4 DB 里 居然没有 Sql server ,难道不支持Sqlserver。因为JBPM 4使用Hibernate,不支持Sqlserver可能性不大,所以自己写相应的create.sql drop.sql 及 hibernate配置文件。测试可以通过。但还是遇到些许问题..A:org.hibernate.exception.ConstraintViolationException: could not insert: [org.jbpm.pvm.internal.history.model.HistoryProcessInstanceImpl]Caused by: java.sql.SQLException: 当 IDENTITY_INSERT 设置为 OFF 时,不能为表 "JBPM4_HIST_PROCINST" 中的标识列插入显式值。JBPM4_HIST_PROCINST : DBID_ bigint not null IDENTITY, 改为 DBID_ bigint not null经查系改Sql时没看仔细,该表非IDENTITY id。B:org.hibernate.exception.ConstraintViolationException: could not insert: [org.jbpm.pvm.internal.model.ExecutionImpl]Caused by: java.sql.SQLException: 违反了 UNIQUE KEY 约束 "UQ__JBPM4_EXECUTION__7D8391DF"。不能在对象 "dbo.JBPM4_EXECUTION" 中插入重复键。ID_ ASCNote that SQL Server doesn"t allow multiple null values in a column witha unique constraint (JBPM4_EXECUTION.ID_).忍痛去掉该约束~2:待续~