[
https://issues.apache.org/jira/browse/HIVE-23283?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Marton Bod updated HIVE-23283:
------------------------------
Attachment: HIVE-23283.1.patch
Status: Patch Available (was: Open)
> Generate random temp ID for lock enqueue and commitTxn
> ------------------------------------------------------
>
> Key: HIVE-23283
> URL: https://issues.apache.org/jira/browse/HIVE-23283
> Project: Hive
> Issue Type: Improvement
> Reporter: Marton Bod
> Assignee: Marton Bod
> Priority: Major
> Attachments: HIVE-23283.1.patch
>
>
> In order to optimize the S4U scope of enqueue lock and commitTxn, currently a
> hardcoded constant (-1) is used to first insert all the lock and ws entries
> with a temporary lockID/commitID. However, in a concurrent environment this
> seems to cause some performance degradation (and deadlock issues with some
> rdbms) as multiple concurrent transactions are trying to insert rows with the
> same primary key (e.g. (-1, 1), (-1, 2), (-1, 3), .. etc. for (extID/intID)
> in HIVE_LOCKS). The proposed solution is to replace the constant with a
> random generated negative number, which seems to resolve this issue.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)