[
https://jira.jboss.org/jira/browse/JBPM-2526?page=com.atlassian.jira.plug...
]
Tom Baeyens commented on JBPM-2526:
-----------------------------------
introduce JBPM4_PROPERTIES and schema version property used to be a separate issue :
JBPM-2527
implement jbpm key generation
-----------------------------
Key: JBPM-2526
URL:
https://jira.jboss.org/jira/browse/JBPM-2526
Project: jBPM
Issue Type: Task
Security Level: Public(Everyone can see)
Reporter: Tom Baeyens
Assignee: Tom Baeyens
Priority: Critical
Fix For: jBPM 4.2
mechanism:
1) add JBPM4_PROPERTIES table (See also JBPM-2527)
2) define a property called NEXTID with a long value that is initialized at 1
3) define a KeyGeneratorImpl in the process-engine context, with eager initialization
4) make sure that all hibernate entities during construction get a value from the id
generator
- each id generator will acquire a block of ids by updating the NEXTID property
- block acquisition is guarded with optimistic locking
- ids will be consumed from the block (very fast, without db access)
5) remove all the explicit flushes
6) implement a DefaultKeyGenerator that only uses in memory key generation in case people
work without persistence
public abstract class KeyGenerator {
// similar as ScriptManager
public static KeyGenerator getKeyGenerator() {...}
// similar as ScriptManager
public static KeyGenerator getDefaultKeyGenerator() {...}
public long getNextId() {...}
}
Motivations:
1) database portability : see also JBPM-2510
2) performance
JBPM-2510
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira