]> git.proxmox.com Git - pve-storage.git/commit - PVE/Storage.pm
plugin loader: add an APIAGE
authorWolfgang Bumiller <w.bumiller@proxmox.com>
Fri, 16 Nov 2018 12:54:44 +0000 (13:54 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 19 Nov 2018 09:47:46 +0000 (10:47 +0100)
commit042dd4be1f0e8c58940550d84572a890e5071904
tree0e7ab645026f0c14630d2a86fdae89a27d0e4e01
parent49cc7802f752be39ad880146094270e936081d5b
plugin loader: add an APIAGE

With the addition of the map/unmap_volume() methods we made
an (actually unnecessary) API version bump.
All current users of these methods fall back to path() when
they return undef, so plugins implementing version 1 are
in fact compatible currently. (In fact, the default
Plugin::map_volume() could fall back to it on its own, but
doesn't currently).

For now let's just allow plugins older plugins to also be
loaded by introducing an API age variable. With it, if we
have a reason to break older plugins, we can have a
deprecation period during which older plugins cause a
warning instead of refusing to load altogether.

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
PVE/Storage.pm