From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id 4A3C51FF0C1 for ; Wed, 26 Aug 2026 15:49:24 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id B25E12132C; Wed, 26 Aug 2026 15:49:23 +0200 (CEST) Content-Type: text/plain; charset=UTF-8 Date: Wed, 26 Aug 2026 15:49:19 +0200 Message-Id: Subject: Re: [PATCH datacenter-manager/proxmox v2 00/20] inject application context via API macro for easier integration testing From: =?utf-8?q?Michael_K=C3=B6ppl?= To: "Lukas Wagner" , Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 X-Mailer: aerc 0.22.0 References: <20260820145220.418032-1-l.wagner@proxmox.com> In-Reply-To: <20260820145220.418032-1-l.wagner@proxmox.com> X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1787752151898 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.981 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: S35IM6WXZQ5UW27Y26SITSJIZ7ZPRIXH X-Message-ID-Hash: S35IM6WXZQ5UW27Y26SITSJIZ7ZPRIXH X-MailFrom: m.koeppl@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox Datacenter Manager development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: I like the general idea of this series! Haven't done an in-depth review yet (will do so for v3), but had a look at the implementation in the proxmox-router, proxmox-rest-server, proxmox-apimacro crates. The changes there look good to me and seem simple enough, especially considering the impact of the changes made to how we would test PDM, etc. The only change I'd make there is what Dominik already noted regarding the State wrapper, not only because of the the limitation that using any other parameter of any type named "State" wouldn't work anymore, but also because the name seems a bit too generic. Based on the implementation for the subscription API in PDM, this approach seems very intuitive to me. Will do a more in-depth review for v3. On Thu Aug 20, 2026 at 4:52 PM CEST, Lukas Wagner wrote: > TL;DR: Inject essential runtime config, client factory, etc. as an applic= ation > context object and allow to retrieve this object easily in an API handler= via > the API macro. This allows us directly call API handler implementations f= rom [snip]