Skip to content

Commit

Permalink
Replace gRPC code generation tool from Zync to Buf
Browse files Browse the repository at this point in the history
This commit updates the codebase to utilize Buf for generating gRPC code instead of Zync.

Signed-off-by: shivas1516 <[email protected]>
  • Loading branch information
shivas1516 committed Mar 10, 2024
1 parent a2f3fca commit 67c0c08
Show file tree
Hide file tree
Showing 17 changed files with 4,474 additions and 4,758 deletions.
2 changes: 2 additions & 0 deletions cmd/db-manager/v1beta1/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ const (
var dbIf common.KatibDBInterface

type server struct {
api_pb.UnimplementedDBManagerServer
health_pb.UnimplementedHealthServer
}

// Report a log of Observations for a Trial.
Expand Down
1 change: 1 addition & 0 deletions cmd/suggestion/goptuna/v1beta1/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ const (
)

type healthService struct {
health_pb.UnimplementedHealthServer
}

func (s *healthService) Check(ctx context.Context, in *health_pb.HealthCheckRequest) (*health_pb.HealthCheckResponse, error) {
Expand Down
27 changes: 27 additions & 0 deletions pkg/apis/manager/health/buf.gen.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
version: v1
managed:
enabled: true
go_package_prefix:
default: github.com/kubeflow/katib/.
except:
- buf.build/googleapis/googleapis
plugins:
- plugin: buf.build/grpc/go:v1.3.0
out: ./
opt:
- paths=source_relative
# Choose one of the following protocol buffers plugin configurations
# based on your requirements
- plugin: buf.build/protocolbuffers/go:v1.33.0
out: ./
opt:
- paths=source_relative
# OR
# - plugin: buf.build/protocolbuffers/go
# out: ./
# opt:
# - paths=source_relative
- plugin: buf.build/grpc/python:v1.62.0
out: python
- plugin: buf.build/protocolbuffers/python
out: python
7 changes: 7 additions & 0 deletions pkg/apis/manager/health/buf.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
version: v1
breaking:
use:
- FILE
lint:
use:
- DEFAULT
24 changes: 0 additions & 24 deletions pkg/apis/manager/health/build.sh

This file was deleted.

Loading

0 comments on commit 67c0c08

Please sign in to comment.