if other_rm.state < ResourceState.READY:
self.ec.schedule(self.reschedule_delay, self.deploy)
+
+ elif other_rm.state == ResourceState.FAILED:
+ msg = "Failed to deploy resource"
+ self.error(msg)
+ raise RuntimeError(msg)
+
else:
self.do_discover()
self.do_provision()
def state(self):
"""
Returns the state of the RM.
+
+ The state method should never raise an exception, instead if an
+ error occurs it should log the error and invoke the self.do_fail
+ method as follows:
+
+ self.error(msg, out, err)
+ self.do_fail()
"""
return super(RMClass, self).state