From b781f06791afe27a780b51bc9a232ecac97a894b Mon Sep 17 00:00:00 2001
From: Mark Reynolds <mreynolds@redhat.com>
Date: Mon, 18 May 2015 14:51:55 -0400
Subject: [PATCH 325/327] Ticket 48158 - cleanAllRUV task limit not being
enforced correctly
Bug Description: The task limit check was only counting tasks that had
already begun the cleaning process. If the task was waiting
for a replica to be online before it starting the cleaning
process, then task count was not incremented, and limit
check was essentially bypassed.
Fix Description: Use the "pre-cleaned" rid list to determine the task count.
The pre-cleaned list is updated as soon a task request
comes in - not once the cleaning starts.
https://fedorahosted.org/389/ticket/48158
Reviwed by: nhosoi(Thanks!)
(cherry picked from commit d774b19fe6a1626cca3c92b125e56a22771bba5a)
(cherry picked from commit fd427d1db9820ce3bb81e2b72e20caa7e35bf6f9)
---
ldap/servers/plugins/replication/repl5_replica_config.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ldap/servers/plugins/replication/repl5_replica_config.c b/ldap/servers/plugins/replication/repl5_replica_config.c
index a9aeed3..ae4c2ff 100644
--- a/ldap/servers/plugins/replication/repl5_replica_config.c
+++ b/ldap/servers/plugins/replication/repl5_replica_config.c
@@ -3152,7 +3152,7 @@ get_cleanruv_task_count()
slapi_rwlock_wrlock(rid_lock);
for(i = 0; i < CLEANRIDSIZ; i++){
- if(cleaned_rids[i] != 0){
+ if(pre_cleaned_rids[i] != 0){
count++;
}
}
--
1.9.3