Bug 778819 (SOA-1269) - REGRESSION: New jBPM indexes breaks db initialization
Summary: REGRESSION: New jBPM indexes breaks db initialization
Keywords:
Status: CLOSED NEXTRELEASE
Alias: SOA-1269
Product: JBoss Enterprise SOA Platform 4
Classification: JBoss
Component: JBPM - within SOA, Configuration, Deployment
Version: 4.3 CP01
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: ---
: 4.3 CP01
Assignee: Julian Coleman
QA Contact:
URL: http://jira.jboss.org/jira/browse/SOA...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-04-03 09:46 UTC by Jiri Pechanec
Modified: 2009-04-20 15:58 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
MySQL/RHEL5
Last Closed: 2009-04-20 15:58:57 UTC
Type: Bug


Attachments (Terms of Use)
SOA-1269.patch (1.73 KB, text/x-patch)
2009-04-03 12:19 UTC, Julian Coleman
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBPM-2094 0 None None None Never
Red Hat Issue Tracker SOA-1269 0 None None None Never

Description Jiri Pechanec 2009-04-03 09:46:27 UTC
Date of First Response: 2009-04-03 07:10:59
project_key: SOA

There are errors in jBPM db initalization with MySQL. During startut an exception is thrown
2009-04-03 05:14:40,195 WARN  [org.jboss.system.ServiceController] Problem starting service jboss.esb:service=JBPMDatabaseInitializer
com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: Duplicate key name 'FK_LOG_ACTION'
        at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:936)
        at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985)
        at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631)
        at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723)
        at com.mysql.jdbc.Connection.execSQL(Connection.java:3250)
        at com.mysql.jdbc.Statement.executeUpdate(Statement.java:1355)
        at com.mysql.jdbc.Statement.executeUpdate(Statement.java:1270)
        at org.jboss.resource.adapter.jdbc.WrappedStatement.executeUpdate(WrappedStatement.java:239)
        at org.jboss.internal.soa.esb.dependencies.DatabaseInitializer.executeSql(DatabaseInitializer.java:145)
        at org.jboss.internal.soa.esb.dependencies.DatabaseInitializer.initDatabase(DatabaseInitializer.java:122)
        at org.jboss.internal.soa.esb.dependencies.DatabaseInitializer.startService(DatabaseInitializer.java:159)
        at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
        at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
        at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
        at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)

When the SQL script is run through CLI client it throws
ERROR 1061 (42000) at line 93: Duplicate key name 'FK_LOG_ACTION'

Comment 1 Julian Coleman 2009-04-03 11:10:59 UTC
This looks like a bug in the jBPM hibernate configuration.  Trying a new SOA build
with the attached patch for jBPM (SOA-1269.patch).


Comment 2 Julian Coleman 2009-04-03 11:11:54 UTC
Attachment: Added: SOA-1269.patch


Comment 3 Julian Coleman 2009-04-03 12:19:57 UTC
Revised patch (typo corrected)

Comment 4 Julian Coleman 2009-04-03 12:19:57 UTC
Attachment: Added: SOA-1269.patch


Comment 5 Julian Coleman 2009-04-03 12:20:33 UTC
Attachment: Removed: SOA-1269.patch 


Comment 6 Alejandro Guizar 2009-04-03 15:37:53 UTC
The patch is good. I reviewed the remaining many-to-ones to be sure their name started with IDX as opposed to FK. I will commit the changes, move the tag and redeploy the maven artifacts.

Comment 7 Alejandro Guizar 2009-04-03 19:16:43 UTC
Hold on - something is not right. In HSQLDB (the build did not get as far as MySQL) the following error occurs.

13:02:55,413 WARN  (JbpmJobExecutor:127.0.0.1:1) [org.hibernate.util.JDBCExceptionReporter] SQL Error: -177, SQLState: 23000
13:02:55,413 ERROR (JbpmJobExecutor:127.0.0.1:1) [org.hibernate.util.JDBCExceptionReporter] Integrity constraint violation - no parent FK375F591A200A8483 table: JBPM_PROCESSINSTANCE in statement [insert into JBPM_LOG (ID_, INDEX_, DATE_, TOKEN_, PARENT_, VARIABLEINSTANCE_, OLDLONGVALUE_, NEWLONGVALUE_, CLASS_) values (null, ?, ?, ?, ?, ?, ?, ?, 'G')]


Comment 8 Alejandro Guizar 2009-04-03 23:20:11 UTC
Nevermind, I committed an unrelated change along the patch. I have reverted the extraneous change, moved the tag and redeployed the artifacts.

Comment 9 Alejandro Guizar 2009-04-04 13:49:14 UTC
Link: Added: This issue related JBPM-2119


Comment 10 Alejandro Guizar 2009-04-04 13:50:30 UTC
Link: Added: This issue related JBPM-2094


Comment 11 Alejandro Guizar 2009-04-04 13:50:46 UTC
Link: Removed: This issue related JBPM-2119 


Comment 12 Julian Coleman 2009-04-06 10:31:31 UTC
This is fixed in the (new) jBPM 3.2.5 SP5 tag.
This will be incorporated into CR7.


Comment 13 Jiri Pechanec 2009-04-08 13:09:12 UTC
Verified in CR7

Comment 14 Len DiMaggio 2009-04-09 12:24:39 UTC
Setting new "Affects Testing, Regression, Blocks Testing Fields"

Comment 15 Len DiMaggio 2009-04-09 12:25:12 UTC
Setting new "Affects Testing, Regression, Blocks Testing Fields"

Comment 16 Len DiMaggio 2009-04-09 12:25:12 UTC
Blocked Tests: Added: jBPM testing with MySQL, perhaps other DBs
Affects Testing?: Added: [Regression?, Blocks Testing?]


Comment 17 Len DiMaggio 2009-04-09 12:25:28 UTC
Re-closing after setting new "Affects Testing, Regression, Blocks Testing Fields"

Comment 18 Len DiMaggio 2009-04-20 15:58:30 UTC
Edited to match changes in 'affects testing' fields  (? character removed from field names for easier querying)

Comment 19 Len DiMaggio 2009-04-20 15:58:48 UTC
Affects Testing: Removed: [Regression?, Blocks Testing?] Added: [Regression, Blocks Testing]



Note You need to log in before you can comment on or make changes to this bug.