MCPcopy
hub / github.com/rueckstiess/mtools / restart

Method restart

mtools/mlaunch/mlaunch.py:1188–1201  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1186 self.discover()
1187
1188 def restart(self):
1189
1190 # get all running processes
1191 processes = self._get_processes()
1192 procs = [processes[k] for k in list(processes.keys())]
1193
1194 # stop nodes via stop command
1195 self.stop()
1196
1197 # wait until all processes terminate
1198 psutil.wait_procs(procs)
1199
1200 # start nodes again via start command
1201 self.start()
1202
1203 # --- below are api helper methods, can be called after creating an
1204 # MLaunchTool() object

Callers 1

initMethod · 0.95

Calls 4

_get_processesMethod · 0.95
stopMethod · 0.95
startMethod · 0.95
keysMethod · 0.80

Tested by

no test coverage detected