You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since #187 landed I figured I would try to see if my simple hello world example would work on the latest master where I use the following client, connect to the helloworld-server, wait for a few RPCs then kill the server.
#20456 0x000055555578e974 in <C as tower_make::make_connection::MakeConnection<Target>>::poll_ready (self=0x555556109598, cx=0x7ffff45b6aa8) at /home/bmwill/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/tower-make-0.3.0/src/make_connection.rs:41
#20457 0x000055555578d991 in <tonic::transport::service::connector::Connector<C> as tower_service::Service<http::uri::Uri>>::poll_ready (self=0x555556109598, cx=0x7ffff45b6aa8) at /home/bmwill/w/tonic/tonic/src/transport/service/connector.rs:56
#20458 0x000055555578e974 in <C as tower_make::make_connection::MakeConnection<Target>>::poll_ready (self=0x555556109598, cx=0x7ffff45b6aa8) at /home/bmwill/.cargo/registry/src/jackfan.us.kg-1ecc6299db9ec823/tower-make-0.3.0/src/make_connection.rs:41
#20459 0x000055555578d991 in <tonic::transport::service::connector::Connector<C> as tower_service::Service<http::uri::Uri>>::poll_ready (self=0x555556109598, cx=0x7ffff45b6aa8) at /home/bmwill/w/tonic/tonic/src/transport/service/connector.rs:56
From the stack trace it looks like the Service::poll_ready impl for Connector calls MakeConnection::poll_ready and MakeConnection::poll_ready calls Service::poll_ready resulting in an infinite loop.
I tried to bisect the stack overflow and it appears that b90c340 (feat(transport): Allow custom IO and UDS example (#184), 2019-12-13) may be the culprit.
The text was updated successfully, but these errors were encountered:
bmwill
changed the title
Stack overflow when using a service with a broken connection
Stack overflow when using a client with a broken connection
Dec 15, 2019
b90c340 (feat(transport): Allow custom IO and UDS example (#184),
2019-12-13) changed the Connector type to be more generic instead of
only allowing the HttpConnector type, during this change the
`Service::poll_ready` impl was changed from calling
`MakeConnection::poll_ready` on `self.http` to `self` resulting in
infinite recursion due to the blanket imple of
`MakeConnection::poll_ready` calling `Service::poll_ready`.
This fixes the bug by calling `MakeConnection::poll_ready` on
`self.inner` instead of `self`.
Fixes#191
b90c340 (feat(transport): Allow custom IO and UDS example (hyperium#184),
2019-12-13) changed the Connector type to be more generic instead of
only allowing the HttpConnector type, during this change the
`Service::poll_ready` impl was changed from calling
`MakeConnection::poll_ready` on `self.http` to `self` resulting in
infinite recursion due to the blanket imple of
`MakeConnection::poll_ready` calling `Service::poll_ready`.
This fixes the bug by calling `MakeConnection::poll_ready` on
`self.inner` instead of `self`.
Fixeshyperium#191
Since #187 landed I figured I would try to see if my simple hello world example would work on the latest master where I use the following client, connect to the helloworld-server, wait for a few RPCs then kill the server.
Unexpectedly I instead am greeted by a stack overflow (instead of an error) when I kill the server:
Stack Trace
From the stack trace it looks like the
Service::poll_ready
impl forConnector
callsMakeConnection::poll_ready
andMakeConnection::poll_ready
callsService::poll_ready
resulting in an infinite loop.I tried to bisect the stack overflow and it appears that
b90c340 (feat(transport): Allow custom IO and UDS example (#184), 2019-12-13) may be the culprit.
The text was updated successfully, but these errors were encountered: