Skip to content

Commit

Permalink
move analytics rpc to common rpc path
Browse files Browse the repository at this point in the history
  • Loading branch information
paulwe committed Jun 6, 2024
1 parent 429fec7 commit 55b2fa8
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 31 deletions.
14 changes: 7 additions & 7 deletions magefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,17 +48,17 @@ func Proto() error {
"livekit_room.proto",
"livekit_sip.proto",
}
grpcProtoFiles := []string{
protoFiles := []string{
"livekit_agent.proto",
"livekit_analytics.proto",
"rpc/analytics.proto",
"livekit_internal.proto",
"livekit_models.proto",
"livekit_rtc.proto",
"livekit_webhook.proto",
}
infraProtoFiles := []string{
grpcProtoFiles := []string{
"infra/link.proto",
"rpc/analytics.proto",
}
psrpcProtoFiles := []string{
"rpc/agent.proto",
Expand Down Expand Up @@ -109,7 +109,7 @@ func Proto() error {
if err := cmd.Run(); err != nil {
return err
}
fmt.Println("generating grpc protobuf")
fmt.Println("generating protobuf")
args = append([]string{
"--go_out", target,
"--go-grpc_out", target,
Expand All @@ -118,13 +118,13 @@ func Proto() error {
"--plugin=go=" + protocGoPath,
"--plugin=go-grpc=" + protocGrpcGoPath,
"-I=./protobufs",
}, grpcProtoFiles...)
}, protoFiles...)
cmd = exec.Command(protoc, args...)
connectStd(cmd)
if err := cmd.Run(); err != nil {
return err
}
fmt.Println("generating infra protobuf")
fmt.Println("generating grpc protobuf")
args = append([]string{
"--go_out", ".",
"--go-grpc_out", ".",
Expand All @@ -133,7 +133,7 @@ func Proto() error {
"--plugin=go=" + protocGoPath,
"--plugin=go-grpc=" + protocGrpcGoPath,
"-I=./protobufs",
}, infraProtoFiles...)
}, grpcProtoFiles...)
cmd = exec.Command(protoc, args...)
connectStd(cmd)
if err := cmd.Run(); err != nil {
Expand Down
4 changes: 1 addition & 3 deletions protobufs/rpc/analytics.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,7 @@
syntax = "proto3";

package livekit;
option go_package = "github.com/livekit/protocol/livekit/rpc";
option csharp_namespace = "LiveKit.Proto";
option ruby_package = "LiveKit::Proto";
option go_package = "github.com/livekit/protocol/rpc";

import "google/protobuf/empty.proto";
import "livekit_analytics.proto";
Expand Down
10 changes: 4 additions & 6 deletions livekit/rpc/analytics.pb.go → rpc/analytics.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 12 additions & 15 deletions livekit/rpc/analytics_grpc.pb.go → rpc/analytics_grpc.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 55b2fa8

Please sign in to comment.