-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Add api Go module and move all protos under api #10151
Changes from all commits
25a2886
4a45507
3e9cace
e1b94c0
2ac2b9c
171fc14
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
module github.com/containerd/containerd/api | ||
|
||
go 1.22.0 | ||
|
||
require ( | ||
github.com/containerd/ttrpc v1.2.3 | ||
github.com/containerd/typeurl/v2 v2.1.1 | ||
github.com/opencontainers/image-spec v1.1.0 | ||
google.golang.org/genproto/googleapis/rpc v0.0.0-20240401170217-c3f982113cda | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The verions of dependencies in the root go.mod and in the api should be same so it dont cause conflicts later. Currently its at There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This will not change the version in the main repository, the go.mod only needs to specify a minimum version. Since API isn't compiled directly, the version isn't too important here. I think it would only be an issue for API to be ahead of the main repository, but also don't want it to be ahead of 1.6/1.7 since we intend to backport there. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. agree with @dmcgowan here |
||
google.golang.org/grpc v1.59.0 | ||
google.golang.org/protobuf v1.33.0 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Only thing worth considering is to see if those versions are required to be "current" version; some release branches may be on older image-spec and/or grpc; the API module should define minimum required version so that those branches can use the version they need (usually higher than minimum required version) |
||
) | ||
|
||
require ( | ||
github.com/gogo/protobuf v1.3.2 // indirect | ||
github.com/golang/protobuf v1.5.3 // indirect | ||
github.com/opencontainers/go-digest v1.0.0 // indirect | ||
github.com/sirupsen/logrus v1.8.1 // indirect | ||
golang.org/x/net v0.21.0 // indirect | ||
golang.org/x/sys v0.17.0 // indirect | ||
golang.org/x/text v0.14.0 // indirect | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this depends on whether there were changes in the package / module? (currently it reads as it will always be incremented, which may not always be needed)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(basically; versioning should depend on the changes in the api module itself to follow SemVer, which could mean that only a patch release is needed between containerd releases, and versions can be updated separate from containerd releases; order of releasing may still require the API to be tagged before doing a containerd release of course)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sure there will always be changes, we can change the doc if a situation comes up later that doesn't make sense.
It was an idea to remove, but I don't think that will be necessary. There are a few different ways we could handle the versioning, I think the cleanest will be just to not do patch releases for prior minor versions though. The logic is that the highest level API needs to be supported anyway and should not break any compatibility. The whole issue that made this change necessary is related to multiple Go packages in use and in that same scenario the API version will go up. I feel like we have a few different ways we could approach the versioning though and this change gives us more options than we have without it.