Skip to content
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

process monitoring #529

Merged
merged 8 commits into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 0 additions & 24 deletions .idea/watcherTasks.xml

This file was deleted.

3 changes: 2 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,13 @@ require (
github.com/livekit/psrpc v0.5.2
github.com/mackerelio/go-osstat v0.2.4
github.com/maxbrunsfeld/counterfeiter/v6 v6.7.0
github.com/mitchellh/go-ps v1.0.0
github.com/pion/logging v0.2.2
github.com/pion/sdp/v3 v3.0.6
github.com/pion/webrtc/v3 v3.2.23
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.17.0
github.com/prometheus/procfs v0.11.1
github.com/redis/go-redis/v9 v9.3.0
github.com/stretchr/testify v1.8.4
github.com/twitchtv/twirp v8.1.3+incompatible
Expand Down Expand Up @@ -64,7 +66,6 @@ require (
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/client_model v0.4.1-0.20230718164431-9a2bf3000d16 // indirect
github.com/prometheus/common v0.44.0 // indirect
github.com/prometheus/procfs v0.11.1 // indirect
github.com/rogpeppe/go-internal v1.11.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/crypto v0.15.0 // indirect
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,8 @@ github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zk
github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4=
github.com/maxbrunsfeld/counterfeiter/v6 v6.7.0 h1:z0CfPybq3CxaJvrrpf7Gme1psZTqHhJxf83q6apkSpI=
github.com/maxbrunsfeld/counterfeiter/v6 v6.7.0/go.mod h1:RVP6/F85JyxTrbJxWIdKU2vlSvK48iCMnMXRkSz7xtg=
github.com/mitchellh/go-ps v1.0.0 h1:i6ampVEEF4wQFF+bkYfwYgY+F/uYJDktmvLPf7qIgjc=
github.com/mitchellh/go-ps v1.0.0/go.mod h1:J4lOc8z8yJs6vUwklHw2XEIiT4z4C40KtWVN3nvg8Pg=
github.com/nats-io/nats.go v1.31.0 h1:/WFBHEc/dOKBF6qf1TZhrdEfTmOZ5JzdJ+Y3m6Y/p7E=
github.com/nats-io/nats.go v1.31.0/go.mod h1:di3Bm5MLsoB4Bx61CBTsxuarI36WbhAwOm8QrW39+i8=
github.com/nats-io/nkeys v0.4.6 h1:IzVe95ru2CT6ta874rt9saQRkWfe2nFj1NtvYSLqMzY=
Expand Down
418 changes: 255 additions & 163 deletions rpc/io.pb.go

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions rpc/io.proto
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ service IOInfo {
rpc UpdateEgress(livekit.EgressInfo) returns (google.protobuf.Empty);
rpc GetEgress(GetEgressRequest) returns (livekit.EgressInfo);
rpc ListEgress(livekit.ListEgressRequest) returns (livekit.ListEgressResponse);
rpc UpdateMetrics(UpdateMetricsRequest) returns (google.protobuf.Empty);

// ingress
rpc GetIngressInfo(GetIngressInfoRequest) returns (GetIngressInfoResponse);
Expand All @@ -42,6 +43,12 @@ message GetEgressRequest {
string egress_id = 1;
}

message UpdateMetricsRequest {
livekit.EgressInfo info = 1;
float avg_cpu_usage = 3;
float max_cpu_usage = 4;
}

// Query an ingress info from an ingress ID or stream key
message GetIngressInfoRequest {
string ingress_id = 1;
Expand Down
113 changes: 67 additions & 46 deletions rpc/io.psrpc.go

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

Loading
Loading