Re: [pve-devel] [PATCH ha-manager 07/15] manager: read and update rules config

2025-04-25 Thread Fiona Ebner
Am 25.03.25 um 16:12 schrieb Daniel Kral: > Read the rules configuration in each round and update the canonicalized > rules configuration if there were any changes since the last round to > reduce the amount of times of verifying the rule set. > > Signed-off-by: Daniel Kral > --- > As noted inlin

Re: [pve-devel] [PATCH ha-manager 04/15] add rules section config base plugin

2025-04-25 Thread Daniel Kral
On 4/25/25 11:12, Fiona Ebner wrote: Am 25.04.25 um 10:29 schrieb Daniel Kral: On 4/24/25 15:03, Fiona Ebner wrote: Am 25.03.25 um 16:12 schrieb Daniel Kral: + +    $func->($rule, $ruleid); +    } +} + +sub canonicalize { +    my ($class, $rules, $groups, $services) = @_; + +    die "implement

Re: [pve-devel] [RFC cluster/ha-manager 00/16] HA colocation rules

2025-04-25 Thread Daniel Kral
On 4/25/25 14:25, Fiona Ebner wrote: Am 25.04.25 um 10:36 schrieb Daniel Kral: On 4/24/25 12:12, Fiona Ebner wrote: As suggested by @Lukas off-list, I'll also try to make the check selective, e.g. the user has made an infeasible change to the config manually by writing to the file and then wants

Re: [pve-devel] [PATCH ha-manager 05/15] rules: add colocation rule plugin

2025-04-25 Thread Fiona Ebner
Not much to add to Fabian's review :) Am 25.03.25 um 16:12 schrieb Daniel Kral: > diff --git a/src/PVE/HA/Rules/Colocation.pm b/src/PVE/HA/Rules/Colocation.pm > new file mode 100644 > index 000..808d48e > --- /dev/null > +++ b/src/PVE/HA/Rules/Colocation.pm > @@ -0,0 +1,391 @@ > +package PVE::

Re: [pve-devel] [RFC cluster/ha-manager 00/16] HA colocation rules

2025-04-25 Thread Fiona Ebner
Am 25.04.25 um 15:25 schrieb Daniel Kral: > On 4/25/25 14:25, Fiona Ebner wrote: >> Am 25.04.25 um 10:36 schrieb Daniel Kral: >>> On 4/24/25 12:12, Fiona Ebner wrote: >>> As suggested by @Lukas off-list, I'll also try to make the check >>> selective, e.g. the user has made an infeasible change to t

Re: [pve-devel] [PATCH ha-manager 05/15] rules: add colocation rule plugin

2025-04-25 Thread Fiona Ebner
Am 11.04.25 um 13:04 schrieb Daniel Kral: > On 4/3/25 14:16, Fabian Grünbichler wrote: >> On March 25, 2025 4:12 pm, Daniel Kral wrote: >>> +sub check_services_count { >>> +    my ($rules) = @_; >>> + >>> +    my $conflicts = []; >>> + >>> +    foreach_colocation_rule($rules, sub { >>> +    my ($ru

Re: [pve-devel] [PATCH ha-manager 06/15] config, env, hw: add rules read and parse methods

2025-04-25 Thread Fiona Ebner
Am 25.03.25 um 16:12 schrieb Daniel Kral: > diff --git a/src/PVE/HA/Env/PVE2.pm b/src/PVE/HA/Env/PVE2.pm > index 1de4b69..3157e56 100644 > --- a/src/PVE/HA/Env/PVE2.pm > +++ b/src/PVE/HA/Env/PVE2.pm > @@ -28,6 +28,13 @@ PVE::HA::Resources::PVECT->register(); > > PVE::HA::Resources->init(); > >

Re: [pve-devel] applied: [PATCH esxi-import-tools 1/2] listvms: add check for vCLS test whether vm configuration is present

2025-04-25 Thread Daniel Kral
On 4/24/25 19:33, Thomas Lamprecht wrote: Applied, but I had to make a followup for the second patch, which had a logical error that was even reported on package build: --- mypy listvms.py listvms.py:261: error: "None" has no attribute "extraConfig" [attr-defined] --- Would be great if you cou

Re: [pve-devel] [PATCH ha-manager 03/15] usage: add get_service_node and pin_service_node methods

2025-04-25 Thread Daniel Kral
On 4/24/25 14:29, Fiona Ebner wrote: Am 25.03.25 um 16:12 schrieb Daniel Kral: Add methods get_service_node() and pin_service_node() to the Usage class to retrieve and pin the current node of a specific service. Hmm, not sure about calling it "pin", why not "set"? This is used to retrieve t

Re: [pve-devel] [PATCH ha-manager 04/15] add rules section config base plugin

2025-04-25 Thread Daniel Kral
On 4/24/25 15:03, Fiona Ebner wrote: Am 25.03.25 um 16:12 schrieb Daniel Kral: Add a rules section config base plugin to allow users to specify different kinds of rules in a single configuration file. The interface is designed to allow sub plugins to implement their own {decode,encode}_value()

Re: [pve-devel] [RFC cluster/ha-manager 00/16] HA colocation rules

2025-04-25 Thread Daniel Kral
Thanks for the review, Fiona! I have some comments left, one of them is about the last comment about how to migrate HA groups to location rules to give a better illustration why I'd like to allow multiple location rules in the end, hope we're able to do this. On 4/24/25 12:12, Fiona Ebner wr

Re: [pve-devel] [PATCH qemu-server v2 6/13] api2: qemu: add module exposing node migration capabilities

2025-04-25 Thread Christoph Heiss
Thanks for the review! On Thu Apr 24, 2025 at 2:02 PM CEST, Fiona Ebner wrote: > Am 24.04.25 um 13:19 schrieb Christoph Heiss: >> diff --git a/PVE/API2/Qemu/Migration.pm b/PVE/API2/Qemu/Migration.pm >> new file mode 100644 >> index ..34125a15 >> --- /dev/null >> +++ b/PVE/API2/Qemu/Migrati

Re: [pve-devel] [PATCH ha-manager 04/15] add rules section config base plugin

2025-04-25 Thread Fiona Ebner
Am 25.04.25 um 10:29 schrieb Daniel Kral: > On 4/24/25 15:03, Fiona Ebner wrote: >> Am 25.03.25 um 16:12 schrieb Daniel Kral: >>> + >>> +    $func->($rule, $ruleid); >>> +    } >>> +} >>> + >>> +sub canonicalize { >>> +    my ($class, $rules, $groups, $services) = @_; >>> + >>> +    die "implement

Re: [pve-devel] [PATCH pve-installer 4/6] run rustfmt

2025-04-25 Thread Michael Köppl
On 4/23/25 13:56, Christoph Heiss wrote: Have you checked out the latest commit (952832147)? These are apparently the "old" 2021 edition rules which are being applied here - latest master is on the 2024 edition for some time now [0]. The changes here are the exact reverse of some of the changes

Re: [pve-devel] [RFC cluster/ha-manager 00/16] HA colocation rules

2025-04-25 Thread Fiona Ebner
Am 25.04.25 um 10:36 schrieb Daniel Kral: > On 4/24/25 12:12, Fiona Ebner wrote: >> Am 25.03.25 um 16:12 schrieb Daniel Kral: >>> | Canonicalization >>> -- >>> >>> Additionally, colocation rules are currently simplified as follows: >>> >>> - If there are multiple positive colocation rules w