Stop perl modules from starting or ending transactions

VERIFIED WONTFIX

Status

()

Bugzilla
Bugzilla-General
--
enhancement
VERIFIED WONTFIX
12 years ago
10 years ago

People

(Reporter: Wurblzap, Unassigned)

Tracking

Details

(Reporter)

Description

12 years ago
Module subroutines locking tables cannot be called as part of a wider lock. The
(recently gotten rid of) derive_groups hack sporting a tables_already_locked
parameter is not a good example imho. Callsites should take all responsibility
for locking.

For bonus points, we could have a test making sure we don't call bz_lock_tables
outside of .cgi files (with the exception of Bugzilla/DB.pm and Bugzilla/DB/*).

Updated

12 years ago
No longer blocks: 267240

Comment 1

12 years ago
I'm a little iffy on this idea... mostly because my *real* goal is just to
entirely eliminate table locking, as much as possible, and replace it with
transactions.
Severity: normal → enhancement
(Reporter)

Comment 2

12 years ago
We should start aiming a little lower, don't you think?

If we start moving locking outside of modules, we'll end up with LOCK TABLE calls close to what will turn into START TRANSACTION, and UNLOCK TABLES calls will be near to where COMMIT (or ROLLBACK) will be called. So the changes are along the way.
(Reporter)

Comment 3

10 years ago
Morphing, now that we have transactions.
Summary: Stop perl modules from locking tables → Stop perl modules from starting or ending transactions

Comment 4

10 years ago
And actually, there's no reason to prevent modules from starting or ending transactions, since we coded our transaction code in such a way that this doesn't matter.
Status: NEW → RESOLVED
Last Resolved: 10 years ago
Resolution: --- → WONTFIX
(Reporter)

Updated

10 years ago
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.