Bug 1259701 - Spring tests: starting of process gets stuck on Sybase 15.7
Spring tests: starting of process gets stuck on Sybase 15.7
Product: JBoss BPMS Platform 6
Classification: JBoss
Component: jBPM Core (Show other bugs)
Unspecified Unspecified
urgent Severity high
: ER5
: 6.2.0
Assigned To: Maciej Swiderski
Karel Suta
Depends On:
  Show dependency treegraph
Reported: 2015-09-03 07:54 EDT by Karel Suta
Modified: 2015-11-04 11:25 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Stacktrace (8.21 KB, text/plain)
2015-09-03 07:54 EDT, Karel Suta
no flags Details

  None (edit)
Description Karel Suta 2015-09-03 07:54:52 EDT
Created attachment 1069767 [details]

Description of problem:
Tried to run community test -RuntimeManagerInitSpringTest- against Sybase 15.7 database. Test gets stuck when trying to create sample process (RuntimeManagerInitSpringTest.testSimpleTaskInvocation() line: 78).

This error happens just when using Per process instance Runtime manager with local transactions: configurations LOCAL_EMF_PER_PROCESS_INSTANCE_PATH and LOCAL_EM_PER_PROCESS_INSTANCE_PATH.

Hanging stacktrace attached.

Version-Release number of selected component (if applicable):
droolsjbpm-integration, project kie-spring, master branch

How reproducible:
Configure Sybase 15.7 as database for Spring tests:
- Sybase driver as maven dependency
- database properties in AbstractJbpmSpringTest.setupPoolingDataSource()
- hibernate.dialect in resources/jbpm/persistence-local(jta).xml
Run RuntimeManagerInitSpringTest.

Steps to Reproduce:

Actual results:
Test gets stuck in RuntimeManagerInitSpringTest.testSimpleTaskInvocation() line: 78 when testing Per process instance Runtime manager with local transactions.

Expected results:
All tests pass.

Additional info:
Comment 2 Maciej Swiderski 2015-10-19 08:01:53 EDT
problem was caused by Sybase that by default uses all pages locking which is sort of table lock (and indexes). That does not work well for engines such as jBPM which is tailored to run on just rows. So such locking scheme shall be enabled for jBPM tables.

Fix for this is an update to DDL script for sybase to always configure data rows as locking scheme which corresponds to row locking.

Unfortunately this cannot be enabled for hibernate auto ddl (or at least I have no idea how to do it). So the tests must be ran after DDL script based schema creation.

Alternatively system wide settings can be enabled on Sybase to always use data rows locking. Though it might have some side effects for other applications running on same db so this needs to be checked before enabling system wide setting. Command to enable it is as follows:
sp_configure 'lock scheme', 0, datarows


Comment 3 Karel Suta 2015-11-04 11:25:15 EST
Verified with DDL script, test passed.

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