]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr/volumes: implement subvolume based on subvolume template
authorVenky Shankar <vshankar@redhat.com>
Wed, 20 Nov 2019 13:45:44 +0000 (08:45 -0500)
committerRamana Raja <rraja@redhat.com>
Wed, 12 Feb 2020 10:11:59 +0000 (05:11 -0500)
commit4aefbb3e2939bc97a5a2485d6afb10544a0a4b4d
treec86f49fdc6801970cccf4618560a9c0e1be52245
parentbe0746524ec2859b4641411cfb2e8da74c7c8dd3
mgr/volumes: implement subvolume based on subvolume template

subvolume base class implements common routines/helpers and
initializes a metadata manager. later, when v2 subvolume version
is implemented, the metadata manager would be used to persist
subvolume metadata in ceph filesystem. this would allow flexible
metadata management when complex subvolume features are added.

typically, a subvolume would be implemented by subclassing the
subvolume base class and the subvolume template -- instantiating
this would be called a "subvolume object".

with this commit, current subvolume topology is maintained. but
we introduce the concept of subvolume versions. a loader stub
loads available "versions" of subvolumes. right now, the only
available version is v1. since backward compatibility needs to
be maintained for existing subvolumes, the loader API allows
version discovery w/ auto upgradation to the most recent version.

Signed-off-by: Venky Shankar <vshankar@redhat.com>
(cherry picked from commit 97170d72b764ed26e93b45e8e2e7ecc2368a2a04)
src/pybind/mgr/volumes/fs/exception.py
src/pybind/mgr/volumes/fs/operations/versions/__init__.py [new file with mode: 0644]
src/pybind/mgr/volumes/fs/operations/versions/metadata_manager.py [new file with mode: 0644]
src/pybind/mgr/volumes/fs/operations/versions/subvolume_base.py [new file with mode: 0644]
src/pybind/mgr/volumes/fs/operations/versions/subvolume_v1.py [new file with mode: 0644]