]> git.proxmox.com Git - pve-common.git/commitdiff
cgroup: add note w.r.t. adding new params to change_cpu_shares
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 7 Nov 2022 15:04:07 +0000 (16:04 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Mon, 7 Nov 2022 15:04:07 +0000 (16:04 +0100)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/CGroup.pm

index 2114c25090b6b9231a479e4f26aebe40f63e9867..7a83ff8a25cc4fae4b7e4a33dbb904cc3392aff4 100644 (file)
@@ -517,6 +517,10 @@ sub clamp_cpu_shares {
 # It is left to the user to figure this out for now.
 #
 # Dies on error (including a not-running or currently-shutting-down guest).
 # It is left to the user to figure this out for now.
 #
 # Dies on error (including a not-running or currently-shutting-down guest).
+#
+# NOTE: if you add a new param during 7.x you need to break older pve-container/qemu-server versions
+#  that previously passed a `$cgroupv1_default`, which got removed due to being ignored anyway.
+#  otherwise you risk that a old module bogusly passes some cgroup default as your new param.
 sub change_cpu_shares {
     my ($self, $shares) = @_;
 
 sub change_cpu_shares {
     my ($self, $shares) = @_;