diff options
| author | Sandy Walsh <sandy.walsh@rackspace.com> | 2011-05-13 06:12:18 -0700 |
|---|---|---|
| committer | Sandy Walsh <sandy.walsh@rackspace.com> | 2011-05-13 06:12:18 -0700 |
| commit | 31b9cb7b78df8d2d6c0d68f08031b5c3abc8a62e (patch) | |
| tree | 440833567433428f354a10770cf1b7d3bc64225f | |
| parent | 35c37d7d74296bf6362ceb675e4f2c2e7b8f994a (diff) | |
| download | nova-31b9cb7b78df8d2d6c0d68f08031b5c3abc8a62e.tar.gz nova-31b9cb7b78df8d2d6c0d68f08031b5c3abc8a62e.tar.xz nova-31b9cb7b78df8d2d6c0d68f08031b5c3abc8a62e.zip | |
fixup based on Lorin's feedback
| -rw-r--r-- | nova/scheduler/zone_aware_scheduler.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/nova/scheduler/zone_aware_scheduler.py b/nova/scheduler/zone_aware_scheduler.py index 07f86450b..b3d230bd2 100644 --- a/nova/scheduler/zone_aware_scheduler.py +++ b/nova/scheduler/zone_aware_scheduler.py @@ -36,7 +36,7 @@ class ZoneAwareScheduler(driver.Scheduler): """Call novaclient zone method. Broken out for testing.""" return api.call_zone_method(context, method, specs=specs) - def schedule_run_instance(self, context, topic='compute', specs=None, + def schedule_run_instance(self, context, topic='compute', specs={}, *args, **kwargs): """This method is called from nova.compute.api to provision an instance. However we need to look at the parameters being @@ -54,6 +54,10 @@ class ZoneAwareScheduler(driver.Scheduler): for item in build_plan: self.provision_instance(context, topic, item) + def provision_instance(context, topic, item): + """Create the requested instance in this Zone or a child zone.""" + pass + def select(self, context, *args, **kwargs): """Select returns a list of weights and zone/host information corresponding to the best hosts to service the request. Any @@ -111,5 +115,5 @@ class ZoneAwareScheduler(driver.Scheduler): def weigh_hosts(self, num, specs, hosts): """Derived classes must override this method and return - a lists of hosts in [(weight, hostname)] format.""" + a lists of hosts in [{weight, hostname}] format.""" raise NotImplemented() |
