Am 23.03.26 um 5:09 PM schrieb Arthur Bied-Charreton: > On Mon, Mar 23, 2026 at 05:04:15PM +0100, Arthur Bied-Charreton wrote: >> On Mon, Mar 23, 2026 at 03:46:45PM +0100, Fiona Ebner wrote: >>> Am 12.03.26 um 9:40 AM schrieb Arthur Bied-Charreton: >>> > [...] >>> Having the 'model' endpoint below here seems wrong to me, for two reasons: >>> >>> 1. Since the 'cpu' endpoint already returns a result other than an index >>> of sub-endpoints, it cannot at the same time show in its result that the >>> sub-endpoint exists, and this breaks the directory structure. >>> >>> 2. It's below /nodes/ but it's touching cluster-wide configuration. >>> >>> I think we should just have a new, dedicated endpoint, maybe >>> /cluster/qemu/custom-cpu-models? And then, we might want to drop the >>> need for specifying a 'custom-' prefix when using the calls? >> I agree that the current state feels weird. I went with the old patch's >> approach but I should have rethought it a bit more, especially the >> custom- prefix, the URL already carries that so it's quite redundant. >> >> I like the idea of a new /cluster/qemu/custom-cpu-models route, will >> move the endpoint over to pve-manager for v2 and drop the custom- prefix >> in the process. >> >> By that logic, the cpu-flags endpoint should probably also be cluster-wide, >> since it returns data for all nodes in the cluster? It technically takes >> a node parameter, but that is ignored by the handler (both before and >> after this series). What do you think? >> > Just realizing that this would be a breaking change since that endpoint > is pre-existing, would be better not to touch it, my bad...
No worries! If we would have a good reason to move it, we could add a second endpoint, deprecate the old one and drop it with the next major release. But maybe we should keep that endpoint as-is too, since it is concerned with the VM-specific flags on the node (it does depend on the installed qemu-server version, even if new VM-specific flags are rarely addded), and introduce a new one below /cluster/qemu/ for the cluster-wide flags querying? We could still think about deprecating it in the long run and also sending the VM-specific flags via kv and have them via the cluster-wide endpoint, but not sure about that and I don't think it's too relevant for the series. How does that sound?
