[pve-devel] [PATCH common v2 1/3] JSONSchema: add support for array parameter in api calls, cli and config
Thomas Lamprecht
t.lamprecht at proxmox.com
Tue Jun 6 13:24:02 CEST 2023
Am 06/06/2023 um 13:19 schrieb Dominik Csapak:
> ---8<---
> use Storable qw(dclone);
>
> my $normalize;
> $normalize = sub {...};
>
> my $data = /* create large hash here, with nested data */;
>
> while(1) {
> my $newdata = dclone($data);
> $newdata = $normalize->($newdata);
> }
> --->8---
>
>
> executed it and monitored the rss usage, while letting it run for multiple minutes
> the memory usage increased after the initial creation of the hash, and the first
> dclone, but not after.
>
> is that a sufficient test?
yeah, seems fine enough to me.
> maybe i'd use something like 'normalize_legacy_param_formats' ?
would be an improvement over the original convert_params and fine enough for me.
More information about the pve-devel
mailing list