Skip to content

Conversation

@sunshowers
Copy link
Contributor

@sunshowers sunshowers commented Dec 14, 2025

In #9488 we moved versioned Sled Agent types to the sled-agent-types-versions crate. In that PR we moved functional code into that crate as well, living in the same files as types. However, dealing with updating this code can easily go wrong, particularly around merge conflicts.

Move this kind of functional code to an impls module, so that it is always implemented on the latest versions of types.

Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
Comment on lines +165 to +167
///
/// TODO: The serde deserializer does not currently verify uniqueness of
/// dimensions.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smklein fyi -- worth fixing in the future for sure

Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
Created using spr 1.3.6-beta.1
@sunshowers sunshowers changed the title [sled-agent-types] move functional code back to types crate [sled-agent-types] move functional code to impls module Dec 15, 2025
Created using spr 1.3.6-beta.1
Copy link
Contributor

@jgallagher jgallagher left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this a lot more than the earlier extension trait pattern (even as a fan of extension traits in general).

@sunshowers sunshowers merged commit ccabed8 into main Dec 16, 2025
17 checks passed
@sunshowers sunshowers deleted the sunshowers/spr/sled-agent-types-move-functional-code-back-to-types-crate branch December 16, 2025 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants