Merge lp://qastaging/~justin-fathomdb/nova/constraint-scheduler into lp://qastaging/~hudson-openstack/nova/trunk
Status: | Work in progress |
---|---|
Proposed branch: | lp://qastaging/~justin-fathomdb/nova/constraint-scheduler |
Merge into: | lp://qastaging/~hudson-openstack/nova/trunk |
Diff against target: |
1136 lines (+898/-85) 8 files modified
nova/scheduler/constraint.py (+226/-0) nova/scheduler/constraint_lib.py (+254/-0) nova/scheduler/datastore.py (+148/-0) nova/scheduler/driver.py (+13/-3) nova/scheduler/simple.py (+24/-35) nova/scheduler/zone.py (+1/-2) nova/tests/test_constraintlib.py (+170/-0) nova/tests/test_scheduler.py (+62/-45) |
To merge this branch: | bzr merge lp://qastaging/~justin-fathomdb/nova/constraint-scheduler |
Related bugs: | |
Related blueprints: |
Resource partitioning
(Undefined)
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Nachi Ueno (community) | Needs Fixing | ||
Nova Core security contacts | Pending | ||
Review via email:
|
Description of the change
Implementation of constraint-based scheduler.
Created a simple contraint solver and a scheduler that uses it; created constraints that mirrored the existing selection criteria; refactored DB access code to avoid duplication and support future constraints (Working towards 'proximity' allocation or 'specific zone' allocation)
Unmerged revisions
- 725. By justinsb
-
Back-ported fixes from derived branch
- 724. By justinsb
-
Added (derived) unit test for constraint scheduler
- 723. By justinsb
-
Fixed pep8, missing copyrights
- 722. By justinsb
-
Use datastore in simple scheduler for retrieval in non-forced case
- 721. By justinsb
-
Remove DB update code from schedulers; they deal with the datastore now
- 720. By justinsb
-
Refactoring data store so that we're not using DB objects
(Different constraints will likely need different queries, and the DB binding will be problematic) - 719. By justinsb
-
Optimization for when we know we're not the worst constraint
- 718. By justinsb
-
Small cleanup of tests & pep8
- 717. By justinsb
-
Fix logical error, use a priority queue in the constraint solver
- 716. By justinsb
-
A few fixes (passes most simple scheduler tests)
I question the usefulness of best-match algorithms. I don't believe that the best match is really interesting at all. Finding best matches typically involves (and indeed that seems to be what happens in this implementation) looking at the entire set of candidates and ordering them according to some criteria. I don't believe this approach scales, and I don't believe it's necessary. It's not unlikely that the top XX% are all just fine candidates, so finding the very best offers no real advantage. Furthermore, the host that is the best match right now might be significantly worse two minutes from now.