From cd28f843c4e5c463e3f24fc831ea3f07eb186ea9 Mon Sep 17 00:00:00 2001 From: "terry%mozilla.org" Date: Tue, 15 Feb 2000 21:29:14 +0000 Subject: [PATCH] Lock the tables as low-priority when writing. Maybe makes people making changes wait longer, but people doing read-only stuff should now never block for very long. --- webtools/bugzilla/process_bug.cgi | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/webtools/bugzilla/process_bug.cgi b/webtools/bugzilla/process_bug.cgi index b9be355b2b5d..9eb32e1299fb 100755 --- a/webtools/bugzilla/process_bug.cgi +++ b/webtools/bugzilla/process_bug.cgi @@ -482,7 +482,12 @@ sub LogDependencyActivity { # foreach my $id (@idlist) { my %dependencychanged; - SendSQL("lock tables bugs write, bugs_activity write, cc write, profiles write, dependencies write, votes write, keywords write, longdescs write, fielddefs write, keyworddefs read"); + my $write = "LOW_PRIORITY WRITE"; # Might want to make a param to control + # whether we do LOW_PRIORITY ... + SendSQL("LOCK TABLES bugs $write, bugs_activity $write, cc $write, " . + "profiles $write, dependencies $write, votes $write, " . + "keywords $write, longdescs $write, fielddefs $write, " . + "keyworddefs READ, groups READ"); my @oldvalues = SnapShotBug($id); if (defined $::FORM{'delta_ts'} && $::FORM{'delta_ts'} ne $delta_ts) {