emmanuel wrote:
The spec is fairly vague regarding this issue.
The Hibernate algorithm is basically hi*allocSize + lo
where hi is the value in DB, lo is an in memory counter
You can always implement the same behavior as TL using a @GenericGenerator
Emmanuel,
Thanks for the reply. but I'm a little confused about what the hi and lo values represent.
I've beek trying to find some documentation what the hi, and lo, values represent in a hilo generator of the kind Hibernate is using. I looked in the hibernate docs, and all I'm getting is :
"uses a hi/lo algorithm to efficiently generate identifiers of type long, short or int, given a table and column (by default hibernate_unique_key and next_hi respectively) as a source of hi values. The hi/lo algorithm generates identifiers that are unique only for a particular database."
This implies that the hi values are coming from my id table, which is what I would expect. But what is the lo values?
Thanks,
Mal.
p.s. why would it perform that multiplication anyhow?