summaryrefslogtreecommitdiffstats
path: root/ctdb/include
diff options
context:
space:
mode:
authorAmitay Isaacs <amitay@gmail.com>2014-07-24 15:56:41 +1000
committerVolker Lendecke <vl@samba.org>2014-08-04 20:23:45 +0200
commit88f6a6c188b8e43f710c50a9c1f88af660772e3d (patch)
treee6c42efbaa5d96956611eaec008de28a56b270df /ctdb/include
parentf73adff737c8fd3ab797de35bf1463359ce801cd (diff)
downloadsamba-88f6a6c188b8e43f710c50a9c1f88af660772e3d.tar.gz
samba-88f6a6c188b8e43f710c50a9c1f88af660772e3d.tar.xz
samba-88f6a6c188b8e43f710c50a9c1f88af660772e3d.zip
ctdb-locking: Add per database queues for pending and active lock requests
This avoids traversing a single pending queue which is quite expensive when there are lots of pending lock requests. This seems to happen quite a lot on a loaded cluster for notify_index.tdb. Adding per database queues avoids the need to traverse pending queue for that database if there are already the maximum number of active lock requests. Signed-off-by: Amitay Isaacs <amitay@gmail.com> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Mon Aug 4 20:23:45 CEST 2014 on sn-devel-104
Diffstat (limited to 'ctdb/include')
-rw-r--r--ctdb/include/ctdb_private.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/ctdb/include/ctdb_private.h b/ctdb/include/ctdb_private.h
index 68d45a3afe..416cf56f2f 100644
--- a/ctdb/include/ctdb_private.h
+++ b/ctdb/include/ctdb_private.h
@@ -597,6 +597,8 @@ struct ctdb_db_context {
struct ctdb_db_statistics statistics;
+ struct lock_context *lock_current;
+ struct lock_context *lock_pending;
int lock_num_current;
};