github.com/livekit/protocol@v1.16.1-0.20240517185851-47e4c6bba773/protobufs/infra/link.proto (about)

     1  // Copyright 2023 LiveKit, Inc.
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //     http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  syntax = "proto3";
    16  
    17  package rpc;
    18  
    19  import "google/protobuf/timestamp.proto";
    20  
    21  option go_package = "github.com/livekit/protocol/infra";
    22  
    23  service Link {
    24    rpc WatchLocalLinks(WatchLocalLinksRequest) returns (stream WatchLocalLinksResponse);
    25    rpc SimulateLinkState(SimulateLinkStateRequest) returns (SimulateLinkStateResponse);
    26  }
    27  
    28  message WatchLocalLinksRequest {}
    29  
    30  message WatchLocalLinksResponse {
    31    string local_region = 1;
    32    string remote_region = 2;
    33    int64 rtt = 3;
    34    int64 jitter = 4;
    35    double packet_loss = 5;
    36    bool disabled = 6;
    37    google.protobuf.Timestamp last_read = 7;
    38  }
    39  
    40  message SimulateLinkStateRequest {
    41    string local_region = 1;
    42    string remote_region = 2;
    43    optional int64 rtt = 3;
    44    optional int64 jitter = 4;
    45    optional double packet_loss = 5;
    46    optional bool disabled = 6;
    47    int64 timeout = 7;
    48  }
    49  
    50  message SimulateLinkStateResponse {}