'Log requests with exceptions from previous volume operations.'

def _log_volume_error(self, volume_id, retry):

    exc = retry.pop('exc', None)
    if (not exc):
        return
    backends = retry.get('backends', retry.get('hosts'))
    if (not backends):
        return
    last_backend = backends[(-1)]
    LOG.error('Error    scheduling    %(volume_id)s    from    last    vol-service:    %(last_backend)s    :    %(exc)s', {'volume_id': volume_id, 'last_backend': last_backend, 'exc': exc})
