xDS test server: document rpc-behavior metadata, add hostname option (#29475)

* xDS test server: document rpc-behavior metadata, add fail-on option

* Update to address suggestions

* Address more existing rpc-behavior values

* Address comments

* Address comments again
pull/29622/head
Michael Lumish 3 years ago committed by GitHub
parent 17d50f46e1
commit a7a960e446
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      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-<int>`, 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-<int>`, the server should respond with the specified status code and behavior matching ends.
- If the value matches `success-on-retry-attempt-<int>`, 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=<string>` 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

Loading…
Cancel
Save