Ejemplo n.º 1
0
    def revert(self, context, result, flow_failures, volume, **kwargs):
        if isinstance(result, ft.Failure):
            return

        # Restore the source volume status and set the volume to error status.
        common.restore_source_status(context, self.db, kwargs)
        common.error_out(volume)
        LOG.error("Volume %s: create failed", volume.id)
        exc_info = False
        if all(flow_failures[-1].exc_info):
            exc_info = flow_failures[-1].exc_info
        LOG.error('Unexpected build error:', exc_info=exc_info)
Ejemplo n.º 2
0
    def revert(self, context, result, flow_failures, **kwargs):
        if isinstance(result, ft.Failure):
            return

        # Restore the source volume status and set the volume to error status.
        volume_id = kwargs["volume_id"]
        common.restore_source_status(context, self.db, kwargs)
        common.error_out_volume(context, self.db, volume_id)
        LOG.error(_LE("Volume %s: create failed"), volume_id)
        exc_info = False
        if all(flow_failures[-1].exc_info):
            exc_info = flow_failures[-1].exc_info
        LOG.error(_LE("Unexpected build error:"), exc_info=exc_info)
Ejemplo n.º 3
0
 def revert(self, context, result, **kwargs):
     if isinstance(result, ft.Failure):
         return
     volume_spec = result.get("volume_spec")
     # Restore the source volume status and set the volume to error status.
     common.restore_source_status(context, self.db, volume_spec)
Ejemplo n.º 4
0
 def revert(self, context, result, **kwargs):
     if isinstance(result, ft.Failure):
         return
     volume_spec = result.get('volume_spec')
     # Restore the source volume status and set the volume to error status.
     common.restore_source_status(context, self.db, volume_spec)