Skip to content

Better documentation on tonic::transport::Server::.timeout function #936

Description

@marlon-sousa

Hello,

I have spent some time digging through the implementation to discover the following:

  1. What is the default timeout if no timeout is set (I see that the default value is None, but what does that mean (a fixed timeout, no timeout, ... ?)
  2. What does this timeout mean? My understanding is that this regulates the amount of time a given request has to executer, after which it will be dropped. Is this true?

I ask this specifically because by looking for help on this topic I read elsewhere that Tonic server wouldn't have a timeout functionality because this could be controlled by clients, but now I see that this functionality does exist.

btw: muy understanding is that once a graceful shutdown future completes, in-flight requests will complete (respecting this timeout setting) and then the server will stop. Is this assumption correct?

It would be nice to document these behaviors so that others can find this information more quickly.

Thanks,
Marlon

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions