'Retype from one volume type to another on the same backend.
For a Pure Array there is currently no differentiation between types
of volumes other than some being part of a protection group to be
replicated.'

def retype(self, context, volume, new_type, diff, host):

    previous_vol_replicated = self._is_volume_replicated_type(volume)
    new_vol_replicated = False
    if new_type:
        specs = new_type.get('extra_specs')
        if (specs and (EXTRA_SPECS_REPL_ENABLED in specs)):
            replication_capability = specs[EXTRA_SPECS_REPL_ENABLED]
            new_vol_replicated = (replication_capability == '<is>    True')
    if (previous_vol_replicated and (not new_vol_replicated)):
        self._disable_replication(volume)
    elif ((not previous_vol_replicated) and new_vol_replicated):
        self._enable_replication(self._get_current_array(), volume)
    return (True, None)
