feat: print IPAM resources as tables that say what they hold - #126
Merged
Merged
Conversation
Every kind used rest.NewDefaultTableConvertor, whose only columns are the name and an RFC3339 creation timestamp. Pool names are long and generated, so `kubectl get ippools` printed a column of digests beside a column of timestamps and nothing that said what any of them held. Each kind now defines its own columns, mirroring what the milo-ipam plugin already prints so the two surfaces agree, with age rendered the way every other Kubernetes resource renders it. Fields that answer a follow-up question rather than identify the object are marked wide.
scotwells
marked this pull request as ready for review
September 23, 2026 00:55
scotwells
requested review from
JoseSzycho,
ecv,
kevwilliams,
mattdjenkinson and
savme
September 23, 2026 00:55
ecv
approved these changes
Sep 23, 2026
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.
Problem
datumctl get ippoolsprints a column of generated names beside a column of RFC3339 timestamps, and nothing else:Every kind used
rest.NewDefaultTableConvertor, whose output is hardcoded to the name and the creation timestamp. You cannot tell what range a pool holds, which family it is, or how full it is without a second command per row.Change
Each kind defines its own columns, mirroring what the
milo-ipamplugin already prints for the same resources so the two surfaces agree. Age uses the elapsed-time form every other Kubernetes resource uses; the absolute time is still in-o yaml.Fields that answer a follow-up rather than identify the object — parent, provisioning class, scope, phase — are marked wide, so they appear under
-o wideand not before. Utilization distinguishes0%from<0.1%: a /64 handed out of a /32 rounds to zero but the pool is not untouched.This fixes every client at once — kubectl, datumctl, the portal — because they all ask the server for the table.
Left out
No API types change, so no regeneration. Worth noting this was invisible until v0.4.1: while every provisioned pool read
0001-01-01T00:00:00Z, the column was uniformly useless and the missing ones did not stand out.