From: Wolfgang Bumiller <w.bumiller@proxmox.com>
To: Fabian Ebner <f.ebner@proxmox.com>
Cc: pve-devel@lists.proxmox.com, pmg-devel@lists.proxmox.com
Subject: Re: [pve-devel] [PATCH proxmox-perl-rs] move apt repositories module to common
Date: Wed, 6 Jul 2022 13:13:18 +0200 [thread overview]
Message-ID: <20220706111318.rav6ba2wi3omt2vq@casey.proxmox.com> (raw)
In-Reply-To: <20220706085419.45987-1-f.ebner@proxmox.com>
On Wed, Jul 06, 2022 at 10:54:17AM +0200, Fabian Ebner wrote:
> while introducing a 'product' parameter to the relevant functions.
>
> Suggested-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
> Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
> ---
>
> I did the changes in Proxmox/Lib/Common.pm (and Makefile) manually.
> Is that the intended way or could I have generated those somehow?
>
> Hope I got these right:
>
> pve-manager (respectively pmg-api) depends and build-depends on
> libproxmox-rs-perl and libpve-rs-perl (respectively libpmg-rs-perl).
> Both are needed, because just upgrading libproxmox-rs-perl doesn't
> make the new functionality available in the product-specific shared
> lib.
>
> New libpve-rs-perl breaks old pve-manager and new libpmg-rs-perl
> breaks old pmg-api.
I mean in theory we could keep the old functions and just have them
forward to the common module with the corresponding product parameter
added, for a little while anyway?
>
> I don't think there's a depends/breaks needed between
> libproxmox-perl-rs and lib{pmg, pve}-rs-perl, but we could also go
> ahead an do that, and have pve-manager and pmg-api only depend on one
> of the above rather than both.
>
> Makefile | 6 +-
> Proxmox/Lib/Common.pm | 8 +
> {pmg-rs => common}/src/apt/mod.rs | 0
> {pmg-rs => common}/src/apt/repositories.rs | 18 ++-
> common/src/mod.rs | 1 +
> pmg-rs/src/lib.rs | 1 -
> pve-rs/src/apt/mod.rs | 1 -
> pve-rs/src/apt/repositories.rs | 162 ---------------------
> pve-rs/src/lib.rs | 1 -
> 9 files changed, 22 insertions(+), 176 deletions(-)
> rename {pmg-rs => common}/src/apt/mod.rs (100%)
> rename {pmg-rs => common}/src/apt/repositories.rs (86%)
> delete mode 100644 pve-rs/src/apt/mod.rs
> delete mode 100644 pve-rs/src/apt/repositories.rs
>
> diff --git a/Makefile b/Makefile
> index 6f9b597..4b59a57 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -41,13 +41,13 @@ pve pmg:
> gen:
> $(call package_template,PMG,pmg_rs)
> $(call package_template,PVE,pve_rs)
> - perl ./scripts/genpackage.pl Common Proxmox::RS::CalendarEvent
> + perl ./scripts/genpackage.pl Common \
> + Proxmox::RS::APT::Repositories \
> + Proxmox::RS::CalendarEvent
> perl ./scripts/genpackage.pl PVE \
> - PVE::RS::APT::Repositories \
> PVE::RS::OpenId \
> PVE::RS::TFA
> perl ./scripts/genpackage.pl PMG \
> - PMG::RS::APT::Repositories \
> PMG::RS::Acme \
> PMG::RS::CSR \
> PMG::RS::OpenId \
> diff --git a/Proxmox/Lib/Common.pm b/Proxmox/Lib/Common.pm
> index d8a0d57..668986d 100644
> --- a/Proxmox/Lib/Common.pm
> +++ b/Proxmox/Lib/Common.pm
> @@ -6,6 +6,14 @@ Proxmox::Lib::Common - base module for rust bindings common between PVE and PMG
>
> =head1 SYNOPSIS
>
> + package Proxmox::RS::APT::Repositories;
> +
> + use base 'Proxmox::Lib::Common';
> +
> + BEGIN { __PACKAGE__->bootstrap(); }
> +
> + 1;
> +
This is just example documentation, no need to do anything to this file
at all.
> package Proxmox::RS::CalendarEvent;
>
> use base 'Proxmox::Lib::Common';
WARNING: multiple messages have this Message-ID
From: Wolfgang Bumiller <w.bumiller@proxmox.com>
To: Fabian Ebner <f.ebner@proxmox.com>
Cc: pve-devel@lists.proxmox.com, pmg-devel@lists.proxmox.com
Subject: Re: [pmg-devel] [pve-devel] [PATCH proxmox-perl-rs] move apt repositories module to common
Date: Wed, 6 Jul 2022 13:13:18 +0200 [thread overview]
Message-ID: <20220706111318.rav6ba2wi3omt2vq@casey.proxmox.com> (raw)
In-Reply-To: <20220706085419.45987-1-f.ebner@proxmox.com>
On Wed, Jul 06, 2022 at 10:54:17AM +0200, Fabian Ebner wrote:
> while introducing a 'product' parameter to the relevant functions.
>
> Suggested-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
> Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
> ---
>
> I did the changes in Proxmox/Lib/Common.pm (and Makefile) manually.
> Is that the intended way or could I have generated those somehow?
>
> Hope I got these right:
>
> pve-manager (respectively pmg-api) depends and build-depends on
> libproxmox-rs-perl and libpve-rs-perl (respectively libpmg-rs-perl).
> Both are needed, because just upgrading libproxmox-rs-perl doesn't
> make the new functionality available in the product-specific shared
> lib.
>
> New libpve-rs-perl breaks old pve-manager and new libpmg-rs-perl
> breaks old pmg-api.
I mean in theory we could keep the old functions and just have them
forward to the common module with the corresponding product parameter
added, for a little while anyway?
>
> I don't think there's a depends/breaks needed between
> libproxmox-perl-rs and lib{pmg, pve}-rs-perl, but we could also go
> ahead an do that, and have pve-manager and pmg-api only depend on one
> of the above rather than both.
>
> Makefile | 6 +-
> Proxmox/Lib/Common.pm | 8 +
> {pmg-rs => common}/src/apt/mod.rs | 0
> {pmg-rs => common}/src/apt/repositories.rs | 18 ++-
> common/src/mod.rs | 1 +
> pmg-rs/src/lib.rs | 1 -
> pve-rs/src/apt/mod.rs | 1 -
> pve-rs/src/apt/repositories.rs | 162 ---------------------
> pve-rs/src/lib.rs | 1 -
> 9 files changed, 22 insertions(+), 176 deletions(-)
> rename {pmg-rs => common}/src/apt/mod.rs (100%)
> rename {pmg-rs => common}/src/apt/repositories.rs (86%)
> delete mode 100644 pve-rs/src/apt/mod.rs
> delete mode 100644 pve-rs/src/apt/repositories.rs
>
> diff --git a/Makefile b/Makefile
> index 6f9b597..4b59a57 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -41,13 +41,13 @@ pve pmg:
> gen:
> $(call package_template,PMG,pmg_rs)
> $(call package_template,PVE,pve_rs)
> - perl ./scripts/genpackage.pl Common Proxmox::RS::CalendarEvent
> + perl ./scripts/genpackage.pl Common \
> + Proxmox::RS::APT::Repositories \
> + Proxmox::RS::CalendarEvent
> perl ./scripts/genpackage.pl PVE \
> - PVE::RS::APT::Repositories \
> PVE::RS::OpenId \
> PVE::RS::TFA
> perl ./scripts/genpackage.pl PMG \
> - PMG::RS::APT::Repositories \
> PMG::RS::Acme \
> PMG::RS::CSR \
> PMG::RS::OpenId \
> diff --git a/Proxmox/Lib/Common.pm b/Proxmox/Lib/Common.pm
> index d8a0d57..668986d 100644
> --- a/Proxmox/Lib/Common.pm
> +++ b/Proxmox/Lib/Common.pm
> @@ -6,6 +6,14 @@ Proxmox::Lib::Common - base module for rust bindings common between PVE and PMG
>
> =head1 SYNOPSIS
>
> + package Proxmox::RS::APT::Repositories;
> +
> + use base 'Proxmox::Lib::Common';
> +
> + BEGIN { __PACKAGE__->bootstrap(); }
> +
> + 1;
> +
This is just example documentation, no need to do anything to this file
at all.
> package Proxmox::RS::CalendarEvent;
>
> use base 'Proxmox::Lib::Common';
next prev parent reply other threads:[~2022-07-06 11:13 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-06 8:54 Fabian Ebner
2022-07-06 8:54 ` [pmg-devel] " Fabian Ebner
2022-07-06 8:54 ` [pve-devel] [PATCH manager] api: apt: switch to common Proxmox::RS::APT::Repositories package Fabian Ebner
2022-07-06 8:54 ` [pmg-devel] " Fabian Ebner
2022-07-06 8:54 ` [pve-devel] [PATCH pmg-api] " Fabian Ebner
2022-07-06 8:54 ` [pmg-devel] " Fabian Ebner
2022-07-06 11:13 ` Wolfgang Bumiller [this message]
2022-07-06 11:13 ` [pmg-devel] [pve-devel] [PATCH proxmox-perl-rs] move apt repositories module to common Wolfgang Bumiller
2022-07-07 7:04 ` Fabian Ebner
2022-07-07 7:04 ` [pmg-devel] " Fabian Ebner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220706111318.rav6ba2wi3omt2vq@casey.proxmox.com \
--to=w.bumiller@proxmox.com \
--cc=f.ebner@proxmox.com \
--cc=pmg-devel@lists.proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.