'Manage an existing ScaleIO snapshot.
:param snapshot: the snapshot to manage
:param existing_ref: dictionary of the form:
{\'source-id\': <id of ScaleIO snapshot>}'

def manage_existing_snapshot(self, snapshot, existing_ref):

    response = self._query_scaleio_volume(snapshot, existing_ref)
    not_real_parent = (response.get('orig_parent_overriden') or response.get('is_source_deleted'))
    if not_real_parent:
        reason = _("The    snapshot's    parent    is    not    the    original    parent    due    to    deletion    or    revert    action,    therefore    this    snapshot    cannot    be    managed.")
        raise exception.ManageExistingInvalidReference(existing_ref=existing_ref, reason=reason)
    ancestor_id = response['ancestorVolumeId']
    volume_id = snapshot.volume.provider_id
    if (ancestor_id != volume_id):
        reason = (_("The    snapshot's    parent    in    ScaleIO    is    %(ancestor)s    and    not    %(volume)s.") % {'ancestor': ancestor_id, 'volume': volume_id})
        raise exception.ManageExistingInvalidReference(existing_ref=existing_ref, reason=reason)
    return {'provider_id': response['id']}
