mesosphere/chronos-utils — pull request #3 by mrdmnd (2014-01-21 22:51:49+00:00)
Title: Add a randomforest option to create many dependent jobs.

Also adds an __init__.py file to lib/texttable so it loads properly.

Here's some (printed) sample output:

Tue Jan 21 14:37:25 mrdmnd@anglerfish ~/airbnb/chronos-utils (random-forests) $ ./chronos.py jobs --createforest 15
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB0', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB1', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB2', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB0']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB3', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB4', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB3', 'DEPENDENTJOB2']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB5', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB3']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB6', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB7', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB5']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB8', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB3', 'DEPENDENTJOB1']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB9', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB6']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB10', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB0']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB11', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB12', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': []}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB13', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB8']}
{'disabled': False, 'async': False, 'command': 'sleep 50', 'name': 'DEPENDENTJOB14', 'executor': '', 'owner': 'rob@fake.com', 'epsilon': 'PT15M', 'parents': ['DEPENDENTJOB4', 'DEPENDENTJOB8']}
Created 15 dependent job(s) on local Chronos