Simplify builder start/stop methods
Having two start and stop methods was a holdover for when the builder and scheduler were separate classes. Move the private _start method into the public startBuilder method, and just call it start for consistency. Same for stop. Change-Id: I924c718a8435adc12831e34ad8803a41bf81346f
This commit is contained in:
committed by
David Shrewsbury
parent
f833deec48
commit
f3fc0c88e6
@@ -30,7 +30,7 @@ pid_file_module = extras.try_imports(['daemon.pidlockfile', 'daemon.pidfile'])
|
||||
class NodePoolBuilderApp(nodepool.cmd.NodepoolApp):
|
||||
|
||||
def sigint_handler(self, signal, frame):
|
||||
self.nb.stopBuilder()
|
||||
self.nb.stop()
|
||||
sys.exit(0)
|
||||
|
||||
def parse_arguments(self):
|
||||
@@ -61,7 +61,7 @@ class NodePoolBuilderApp(nodepool.cmd.NodepoolApp):
|
||||
self.args.upload_workers)
|
||||
|
||||
signal.signal(signal.SIGINT, self.sigint_handler)
|
||||
self.nb.startBuilder()
|
||||
self.nb.start()
|
||||
|
||||
while True:
|
||||
signal.pause()
|
||||
|
||||
Reference in New Issue
Block a user