Closed silvestrpredko closed 1 year ago
I see no reason to implement Future
for server type. There are at least two downsides which are rewriting async function manually(or boxing an async block) and possibly significantly changing codebase.
Handle is multipurpose so having graceful shutdown there isn't a problem in my opinion.
I'm closing this issue. I most likely won't make any significant changes in this library because with hyper 1.0
coming we will write a new server in hyper-util which will make this library obsolete.
This discussion should continue in hyper-util, thanks for bringing this up anyways.
It's more a discussion rather than an issue. What do you think about redesigning a library to be similar to the
hyper::Server
? It will lead to the same experience withgraceful_shutdown
.For example,
Now, I need to get an
handle
object and control it in a separate task. Is it worth changing it to the same behavior as inhyper::Server
? What do you think?