'Get volume metadata.
Returns a json-encoded dict containing all metadata and the restore
version i.e. the version used to decide what actually gets restored
from this container when doing a backup restore.'

def get(self, volume_id):

    container = {'version': CONF.backup_metadata_version}
    self._save_vol_base_meta(container, volume_id)
    self._save_vol_meta(container, volume_id)
    self._save_vol_glance_meta(container, volume_id)
    if container:
        return jsonutils.dumps(container)
    else:
        return None
