Removing internal usage of registerCustomKind #4579
Merged
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.
Description
This follows up on a next step of #3972 - remove the internal usage of registerCustomKind. The static nature of that registration was problematic both for us and for users as the behavior would seem inconsistent.
This change highlighted that several packages are missing from the KubernetesDeserializer - 8db8124 - that commit won't be needed against master if #4511 is committed first, but may be considered for back-porting.
The strategy here is to use some additional jackson logic to convey an element type with list parsing. list is the only built-in path where we may not have a type already associated with the processing - the other calls, such as a get, will pass the expected type directly; have handling to convert, such as with watch events; or can just use the generic.
Type of change
test, version modification, documentation, etc.)
Checklist