Bug 884683 - Race condition in allocation of systems to recipes
Summary: Race condition in allocation of systems to recipes
Keywords:
Status: CLOSED DUPLICATE of bug 872187
Alias: None
Product: Beaker
Classification: Retired
Component: scheduler
Version: 0.10
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: beaker-dev-list
QA Contact:
URL:
Whiteboard: Scheduler
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-12-06 14:50 UTC by Jan Stancek
Modified: 2018-02-06 00:41 UTC (History)
8 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-03-20 03:55:48 UTC
Embargoed:


Attachments (Terms of Use)

Comment 2 Nick Coghlan 2013-01-15 00:46:36 UTC
With the current scheduler implementation, there is a race condition which allows a job to "jump the queue" when a system is released during a scheduling pass. This may result in deadlock if two recipe sets are competing for systems with limited availability, and recipe set A acquires a system or systems needed by recipe set B and vice-versa.

This can be resolved by making the scheduling process more event driven, rather than relying entirely on the current scheduling loop.

Recipe-based scheduling: when a job is first sent to the Beaker server, all recipes are checked against the current pool of idle systems (including dynamic virt resources). If an appropriate system is available, it is assigned immediately, otherwise the recipe enters the recipe queue.

System-based scheduling: when a system becomes free (first added to Beaker, completes execution of a recipe, switched from Broken or Manual back to Automated), Beaker checks the recipe queue for suitable work. If a recipe is found, then it is assigned directly to the system and the system never actually enters the idle pool.

The scheduling loop remains in place to perform cleanup of the recipe queue (e.g. aborting dead recipes that can never be completed because all suitable systems have been removed from Beaker, checking for free resources in the dynamic virtualisation pool)

Comment 3 Raymond Mancy 2013-03-20 03:55:48 UTC

*** This bug has been marked as a duplicate of bug 872187 ***


Note You need to log in before you can comment on or make changes to this bug.