Skip to content

Commit

Permalink
Update Service_Messages.md
Browse files Browse the repository at this point in the history
  • Loading branch information
wubenqi authored Sep 9, 2019
1 parent 5a71e2e commit 5a25603
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion doc/mtproto/Service_Messages.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,10 @@ pong#347773c5 msg_id:long ping_id:long = Pong;
These messages do not require acknowledgments. A pong is transmitted only in response to a ping while a ping can be initiated by either side.

## Deferred Connection Closure + PING
```
ping_delay_disconnect#f3427b8c ping_id:long disconnect_delay:int = Pong;
```

Works like ping. In addition, after this is received, the server starts a timer which will close the current connection disconnect_delay seconds later unless it receives a new message of the same type which automatically resets all previous timers. If the client sends these pings once every 60 seconds, for example, it may set disconnect_delay equal to 75 seconds.

## Request to Destroy Session
Expand Down Expand Up @@ -151,4 +154,4 @@ This message does not require a response or an acknowledgement. If the container

If no http_wait is present in container, default values max_delay=0 (milliseconds), wait_after=0 (milliseconds), and max_wait=25000 (milliseconds) are used.

If the client’s ping of the server takes a long time, it may make sense to set max_delay to a value that is comparable in magnitude to ping time.
If the client’s ping of the server takes a long time, it may make sense to set max_delay to a value that is comparable in magnitude to ping time.

0 comments on commit 5a25603

Please sign in to comment.