'Cleanup after connection has been terminated.
When we clean up a terminated connection between a given connector
and volume, we:
1. Translate the given connector to a host name
2. Remove the volume-to-host mapping if it exists
3. Delete the host if it has no more mappings (hosts are created
automatically by this driver when mappings are created)'

@utils.synchronized('flashsystem-term-conn', external=True)
def terminate_connection(self, volume, connector, **kwargs):

    LOG.debug('enter:    terminate_connection:    volume    %(vol)s    with    connector    %(conn)s.', {'vol': volume, 'conn': connector})
    vdisk_name = volume['name']
    self._wait_vdisk_copy_completed(vdisk_name)
    host_name = self._unmap_vdisk_from_host(vdisk_name, connector)
    if host_name:
        if (not self._get_hostvdisk_mappings(host_name)):
            self._delete_host(host_name)
    LOG.debug('leave:    terminate_connection:    volume    %(vol)s    with    connector    %(conn)s.', {'vol': volume, 'conn': connector})
    return {'driver_volume_type': 'iscsi'}
