Skip to content

set up API versioning machinery for most internal services #8789

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

iliana
Copy link
Contributor

@iliana iliana commented Aug 6, 2025

Part of #8727 (the easy ones)

@iliana iliana requested a review from davepacheco August 6, 2025 21:20
Copy link
Collaborator

@davepacheco davepacheco left a comment

Choose a reason for hiding this comment

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

I'd expect to see changes for three progenitor client packages that aren't here:

  • ntp-admin
  • sled-agent
  • oximeter

SupportedVersion, SupportedVersions, api_versions,
};

api_versions!([
Copy link
Collaborator

Choose a reason for hiding this comment

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

We had talked about versioning the three Clickhouse services separately in separate modules. Did you opt not to?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah. I added a note in this block (just below here) suggesting that whoever finds a need to add a new version to these APIs should determine whether all the services should share the same versions, or whether to split them into modules. Although now a couple of days later I'm questioning my choices.

@davepacheco
Copy link
Collaborator

davepacheco commented Aug 8, 2025

We also need to update the server implementations to actually process the version field. I think that's not critical for R17 but if you don't do it now, could you file a new issue for that and make sure it gets the "important non-blocker" status? (this is in the "deliverable" field of the Reconfigurator project)

Edit: to be clear, that's a change like this:

.version_policy(dropshot::VersionPolicy::Dynamic(Box::new(
dropshot::ClientSpecifiesVersionInHeader::new(
"api-version"
.parse::<http::header::HeaderName>()
.expect("api-version is a valid header name"),
dns_server_api::VERSION_SOA_AND_NS,
),
)))

If it's easy, that would be nice to do now because it'll be easy to forget later and that will break things.

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.

2 participants