From 41b13928ff887611c7c25f11a1dc66e76cd35c03 Mon Sep 17 00:00:00 2001 From: Marcus Granado Date: Fri, 21 May 2010 14:36:56 +0100 Subject: [PATCH] CA-34933: there should be more sessions than tasks Signed-off-by: Marcus Granado --- ocaml/xapi/xapi_globs.ml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ocaml/xapi/xapi_globs.ml b/ocaml/xapi/xapi_globs.ml index 425b044b..85f6f835 100644 --- a/ocaml/xapi/xapi_globs.ml +++ b/ocaml/xapi/xapi_globs.ml @@ -217,15 +217,16 @@ let migration_failure_test_key = "migration_wings_fall_off" (* set in other-conf the disk flushing *) let migration_extra_paths_key = "migration_extra_paths" -(* After this we start to invalidate older sessions *) -let max_sessions = 200 - (* If a session has a last_active older than this we delete it *) let inactive_session_timeout = 24. *. 60. *. 60. (* 24 hrs in seconds *) (* After this we start to delete completed tasks (never pending ones) *) let max_tasks = 200 +(* After this we start to invalidate older sessions *) +(* We must allow for more sessions than running tasks *) +let max_sessions = max_tasks * 2 + let completed_task_timeout = 65. *. 60. (* 65 mins *) let pending_task_timeout = 24. *. 60. *. 60. (* 24 hrs in seconds *) -- 2.39.5