forked from linkerd/linkerd2-proxy-api
-
Notifications
You must be signed in to change notification settings - Fork 0
/
grpc_route.proto
33 lines (25 loc) · 960 Bytes
/
grpc_route.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
syntax = "proto3";
package io.linkerd.proxy.grpc_route;
option go_package = "github.com/linkerd/linkerd2-proxy-api/go/grpc_route";
import "http_route.proto";
message GrpcRouteMatch {
GrpcRpcMatch rpc = 1;
// A set of header value matches that must be satisified. This match is not
// comprehensive, so requests may include headers that are not covered by this
// match.
repeated io.linkerd.proxy.http_route.HeaderMatch headers = 2;
}
message GrpcRpcMatch {
string service = 1;
string method = 2;
}
// Configures a route to respond with a fixed response.
message GrpcFailureInjector {
// The status code to use in the `grpc-status` response. Must be specified.
uint32 code = 1;
// An error message to log and include in the `grpc-message` header.
string message = 2;
// If specified, the rate of requests that should be failed. If not specified,
// ALL requests are failed.
io.linkerd.proxy.http_route.Ratio ratio = 3;
}