-
Notifications
You must be signed in to change notification settings - Fork 160
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Generate the additional code required for connectrpc with the buf tool. Currently, there is no bazel ruleset available for buf. We work around this by invoking the buf binary directly and commiting the generated code in git. To deal with generation, we pin the `protoc-gen-connect-go` version in the go.mod file. A small scaffolding go binary is added to deal with setting up the environment correctly for the buf tool. While this could be a shell script, this is more readable and maintainable. This PR is broken out of the https://github.com/scionproto/scion/tree/connectrpc branch to make incremental review easier. TL;DR: Run `bazel run //tools/buf` to generate the connectrpc code.
- Loading branch information
Showing
28 changed files
with
2,256 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
build: | ||
roots: | ||
- . | ||
excludes: | ||
- anapaya/protobuf | ||
version: v1 | ||
breaking: | ||
use: | ||
- FILE | ||
lint: | ||
use: | ||
- DEFAULT | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
pkg/proto/control_plane/v1/control_planeconnect/BUILD.bazel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
load("//tools/lint:go.bzl", "go_library") | ||
|
||
go_library( | ||
name = "go_default_library", | ||
srcs = [ | ||
"cppki.connect.go", | ||
"drkey.connect.go", | ||
"renewal.connect.go", | ||
"seg.connect.go", | ||
], | ||
importpath = "github.com/scionproto/scion/pkg/proto/control_plane/v1/control_planeconnect", | ||
visibility = ["//visibility:public"], | ||
deps = [ | ||
"//pkg/proto/control_plane:go_default_library", | ||
"@com_connectrpc_connect//:go_default_library", | ||
], | ||
) |
164 changes: 164 additions & 0 deletions
164
pkg/proto/control_plane/v1/control_planeconnect/cppki.connect.go
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.