restate icon indicating copy to clipboard operation
restate copied to clipboard

Port to Hyper 1.0

Open slinkydeveloper opened this issue 2 years ago • 7 comments

### Tasks
- [ ] https://github.com/restatedev/restate/issues/100
- [x] Wait for hyper 1.0 to be released
- [x] Wait for hyper-rustls to support hyper 1.0
- [ ] https://github.com/restatedev/restate/issues/1060
- [ ] Port admin API to hyper 1.0
- [ ] https://github.com/restatedev/restate/issues/1059

slinkydeveloper avatar Feb 17 '23 09:02 slinkydeveloper

When porting to hyper 1.0, we should remove the task spawn within the InvocationTask that drives the connection forward.

slinkydeveloper avatar Feb 17 '23 09:02 slinkydeveloper

Also need to keep track of https://github.com/rustls/hyper-rustls/pull/192

slinkydeveloper avatar Mar 08 '23 09:03 slinkydeveloper

Very relevant PR here: https://github.com/hyperium/hyper/pull/3155

slinkydeveloper avatar May 23 '23 07:05 slinkydeveloper

With version 0.14.25 we can start using the new 1.0 APIs, which hopefully will make the transition smoother: https://github.com/hyperium/hyper/releases/tag/v0.14.25

slinkydeveloper avatar Jul 18 '23 09:07 slinkydeveloper

hyper 1.0 has been released, and hyper-util as well. We need the hyper-rustls and then we can start

slinkydeveloper avatar Nov 20 '23 08:11 slinkydeveloper

In my latest performance measurements, I noticed that the main bottleneck seems to be the invoker currently (the ingress is also causing high CPU load but does not seem be the limiting factor). One thing I noticed in the flamegraphs is that hyper requires a lot of CPU cycles when polling the Body. I haven't found the reason for this problem but it could be that there is some contention on the single TCP connection that the invoker currently uses when talking to the service deployment.

I hope that by upgrading to Hyper 1.1 we will manage to remove the bottleneck from the server.

tillrohrmann avatar Jan 08 '24 11:01 tillrohrmann

To upgrade to hyper 1.0 we still need hyper-rustls to be released with https://github.com/rustls/hyper-rustls/pull/232

slinkydeveloper avatar Jan 09 '24 10:01 slinkydeveloper

completed 🎉

tillrohrmann avatar Aug 08 '24 10:08 tillrohrmann