xref: /aosp_15_r20/external/grpc-grpc/src/proto/grpc/testing/echo_messages.proto (revision cc02d7e222339f7a4f6ba5f422e6413f4bd931f2)
1
2// Copyright 2015 gRPC authors.
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8//     http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15
16syntax = "proto3";
17
18package grpc.testing;
19
20option cc_enable_arenas = true;
21
22import "src/proto/grpc/testing/xds/v3/orca_load_report.proto";
23
24// Message to be echoed back serialized in trailer.
25message DebugInfo {
26  repeated string stack_entries = 1;
27  string detail = 2;
28}
29
30// Error status client expects to see.
31message ErrorStatus {
32  int32 code = 1;
33  string error_message = 2;
34  string binary_error_details = 3;
35}
36
37message RequestParams {
38  bool echo_deadline = 1;
39  int32 client_cancel_after_us = 2;
40  int32 server_cancel_after_us = 3;
41  bool echo_metadata = 4;
42  bool check_auth_context = 5;
43  int32 response_message_length = 6;
44  bool echo_peer = 7;
45  string expected_client_identity = 8; // will force check_auth_context.
46  bool skip_cancelled_check = 9;
47  string expected_transport_security_type = 10;
48  DebugInfo debug_info = 11;
49  bool server_die = 12; // Server should not see a request with this set.
50  string binary_error_details = 13;
51  ErrorStatus expected_error = 14;
52  int32 server_sleep_us = 15; // sleep when invoking server for deadline tests
53  int32 backend_channel_idx = 16; // which backend to send request to
54  bool echo_metadata_initially = 17;
55  bool server_notify_client_when_started = 18;
56  xds.data.orca.v3.OrcaLoadReport backend_metrics = 19;
57  bool echo_host_from_authority_header = 20;
58}
59
60message EchoRequest {
61  string message = 1;
62  RequestParams param = 2;
63}
64
65message ResponseParams {
66  int64 request_deadline = 1;
67  string host = 2;
68  string peer = 3;
69}
70
71message EchoResponse {
72  string message = 1;
73  ResponseParams param = 2;
74}
75