HEX
Server: Apache/2.4.46 (Win64) OpenSSL/1.1.1j PHP/8.4.25
System: Windows NT DESKTOP-4TAV2RJ 10.0 build 19045 (Windows 10) AMD64
User: fred (0)
PHP: 8.4.25
Disabled: NONE
Upload Files
File: C:/Users/fred/anaconda3/pkgs/libgrpc-1.62.2-hf25190f_0/info/test/examples/cpp/deadline/README.md
# Deadline Example

## Overview

This example shows you how to use deadline when calling calls.

### Try it!

Once you have working gRPC, you can build this example using either bazel or cmake.

Run the server, which will listen on port 50051:

```sh
$ ./server
```

Run the client (in a different terminal):

```sh
$ ./client
```

To simulate the test scenario, the test server implements following functionalities:
- Response Delay: The server intentionally delays its response for `delay` request messages to induce timeout conditions.
- Deadline Propagation: Upon receiving a request with the `[propagate me]` prefix, the server forwards it back to itselt.
  This simulates the propagation of deadlines within the system.

If things go smoothly, you will see the client output:

```
[Successful request] wanted = 0, got = 0
[Exceeds deadline] wanted = 4, got = 4
[Successful request with propagated deadline] wanted = 0, got = 0
[Exceeds propagated deadline] wanted = 4, got = 4
```