feat(tui): Migrate compute.aggregate to generated dispatch - #1904
Open
gtema wants to merge 1 commit into
Open
Conversation
Adds deserialize_items to GeneratedResourceBehaviour (matching the
existing ResourceBehaviour default) as the override point for
per-resource microversion dispatch, and scaffolds
components/compute/generated.rs so compute resources can start
adopting the Generated companion pattern already used by network.
compute.aggregate is the first migrated: its list response varies
across 2.1/2.41 (an added `uuid` field), so its generated companion
now carries a canonical AggregateItem struct and dispatches on the
negotiated microversion instead of hardcoding one response type.
aggregates.rs forwards all mechanical methods to it; title drops the
redundant "Compute" prefix ("Compute Aggregates" -> "Aggregates"),
matching network's convention.
flavor/hypervisor/server are not migrated here: each has a genuine
breaking field-type change somewhere in its real microversion history
(flavor.swap i64->i32 at 2.102, hypervisor.id i32->String at 2.53,
server.os_ext_srv_attr_hostname Option<String>->String at 2.90), so
the generator correctly refuses to generate dispatch for them until a
hand-written conversion exists.
Signed-off-by: Artem Goncharov <artem.goncharov@gmail.com>
gtema
force-pushed
the
tui-table-view-dispatch
branch
from
July 30, 2026 16:22
fafc368 to
f035651
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds deserialize_items to GeneratedResourceBehaviour (matching the
existing ResourceBehaviour default) as the override point for
per-resource microversion dispatch, and scaffolds
components/compute/generated.rs so compute resources can start
adopting the Generated companion pattern already used by network.
compute.aggregate is the first migrated: its list response varies
across 2.1/2.41 (an added
uuidfield), so its generated companionnow carries a canonical AggregateItem struct and dispatches on the
negotiated microversion instead of hardcoding one response type.
aggregates.rs forwards all mechanical methods to it; title drops the
redundant "Compute" prefix ("Compute Aggregates" -> "Aggregates"),
matching network's convention.
flavor/hypervisor/server are not migrated here: each has a genuine
breaking field-type change somewhere in its real microversion history
(flavor.swap i64->i32 at 2.102, hypervisor.id i32->String at 2.53,
server.os_ext_srv_attr_hostname Option->String at 2.90), so
the generator correctly refuses to generate dispatch for them until a
hand-written conversion exists.
Signed-off-by: Artem Goncharov artem.goncharov@gmail.com