Implement simple random spillback policy. (#1493)

* spillback policy implementation: global + local scheduler

* modernize global scheduler policy state; factor out random number engine and generator

* Minimal version.

* Fix test.

* Make load balancing test less strenuous.
This commit is contained in:
Alexey Tumanov
2018-02-13 00:09:35 -08:00
committed by Robert Nishihara
parent f2b6a7b58d
commit 844a6afcdd
9 changed files with 162 additions and 32 deletions
+3 -1
View File
@@ -302,7 +302,9 @@ class TestGlobalScheduler(unittest.TestCase):
num_retries -= 1
time.sleep(0.1)
self.assertEqual(num_tasks_done, num_tasks)
# Tasks can either be queued or in the global scheduler due to
# spillback.
self.assertEqual(num_tasks_done + num_tasks_waiting, num_tasks)
@unittest.skipIf(
os.environ.get('RAY_USE_NEW_GCS', False),