You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Request]: TECH DEBT - Custom type for resource labels. #1359
As @Ronitsabhaya75 observed in #1123, our ManagedResource uses a [String: String] to represent metadata labels, which can admit data that's not valid.
Further, the only label validation that we were performing was in NetworkConfiguration.
I'm starting to put together a proposal for what a 1.0 API/SDK should encompass and will be using network resource management as a proving ground. I'll post that as a discussion topic within the next few days and then we can go back and forth between incremental changes and refining the network type until we've established a nice set of patterns that we can apply to the other resource types.
We need to keep individual PRs minimal so that they are readily reviewable. This first bit of work:
Creates a new ResourceLabels type.
Adds an AppError type that supports structured logging and delegates message presentation to the error receiver, and derives a ResourceLabels.LabelError subtype to represent label validation errors.
Extracts the label validation code from NetworkConfiguration into this type (relocating unit tests as necessary).
Activity
jglogan commentedon Mar 28, 2026
@saehejkang I'm finally getting back to being able to look at PRs and I remembered your #1126 for the managed resource error type.
Let's have a look at both of these and see how best to reconcile them.
Create ResourceLabels and use for ManagedResource, NetworkConfigurati…
Create ResourceLabels and use for ManagedResource, NetworkConfigurati…