diff --git a/doc/xds-test-descriptions.md b/doc/xds-test-descriptions.md index 79c874dd3d6..a0b5f15d42f 100644 --- a/doc/xds-test-descriptions.md +++ b/doc/xds-test-descriptions.md @@ -17,6 +17,16 @@ Server should accept these arguments: * When set to true it uses XdsServerCredentials with the test server for security test cases. In case of secure mode, port and maintenance_port should be different. +In addition, when handling requests, if the initial request metadata contains the `rpc-behavior` key, it should modify its handling of the request as follows: + + - If the value matches `sleep-`, the server should wait the specified number of seconds before resuming behavior matching and RPC processing. + - If the value matches `keep-open`, the server should never respond to the request and behavior matching ends. + - If the value matches `error-code-`, the server should respond with the specified status code and behavior matching ends. + - If the value matches `success-on-retry-attempt-`, and the value of the `grpc-previous-rpc-attempts` metadata field is equal to the specified number, the normal RPC processing should resume and behavior matching ends. + - A value can have a prefix `hostname=` followed by a space. In that case, the rest of the value should only be applied if the specified hostname matches the server's hostname. + +The `rpc-behavior` header value can have multiple options separated by commas. In that case, the value should be split by commas and the options should be applied in the order specified. If a request has multiple `rpc-behavior` metadata values, each one should be processed that way in order. + ## Client The base behavior of the xDS test client is to send a constant QPS of unary