Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(537)

Issue 6597047: Host scheduler refactoring. Move HostScheduler out of monitor_db. (Closed)

Created:
9 years, 9 months ago by DaleCurtis
Modified:
9 years, 7 months ago
Reviewers:
ericli
CC:
chromium-os-reviews_chromium.org, truty+cc_chromium.org, sosa+cc_chromium.org, seano+cc_chromium.org, ericli
Visibility:
Public.

Description

Host scheduler refactoring. Move HostScheduler out of monitor_db. In order to facilitate site extensibility of HostScheduler we need to factor out the dependence on global variables in monitor_db. I modeled this refactoring off of monitor_db_cleanup. The main changes I've made are as follows: 1. Move BaseHostScheduler, site import, and SchedulerError out of monitor_db. SchedulerError must be moved to prevent a cyclical dependency. 2. Convert staticmethod/classmethods in BaseHostScheduler, to normal methods. 3. Fix unit tests and monitor_db to import SchedulerError from host_scheduler. Change-Id: I0c10b79e70064b73121bbb347bb71ba15e0353d1 BUG=chromium-os:12654 TEST=Ran unit tests. Tested with private Autotest instance. Committed: http://chrome-svn/viewvc/chromeos?view=rev&revision=aa51336

Patch Set 1 #

Patch Set 2 : Extra line. #

Total comments: 2

Patch Set 3 : Revert name change. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+447 lines, -442 lines) Patch
A scheduler/host_scheduler.py View 1 2 1 chunk +424 lines, -0 lines 0 comments Download
M scheduler/monitor_db.py View 1 8 chunks +18 lines, -437 lines 0 comments Download
M scheduler/monitor_db_functional_test.py View 2 chunks +3 lines, -3 lines 0 comments Download
M scheduler/monitor_db_unittest.py View 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
DaleCurtis
9 years, 9 months ago (2011-02-28 20:51:21 UTC) #1
ericli
LGTM with nit. http://codereview.chromium.org/6597047/diff/6/scheduler/host_scheduler.py File scheduler/host_scheduler.py (right): http://codereview.chromium.org/6597047/diff/6/scheduler/host_scheduler.py#newcode23 scheduler/host_scheduler.py:23: class base_host_scheduler(metahost_scheduler.HostSchedulingUtility): ClassName uppercase.
9 years, 9 months ago (2011-02-28 22:41:16 UTC) #2
DaleCurtis
9 years, 9 months ago (2011-03-01 00:25:36 UTC) #3
http://codereview.chromium.org/6597047/diff/6/scheduler/host_scheduler.py
File scheduler/host_scheduler.py (right):

http://codereview.chromium.org/6597047/diff/6/scheduler/host_scheduler.py#new...
scheduler/host_scheduler.py:23: class
base_host_scheduler(metahost_scheduler.HostSchedulingUtility):
On 2011/02/28 22:41:16, ericli wrote:
> ClassName uppercase.

Done.

Powered by Google App Engine
This is Rietveld 408576698