Closed fcfangcc closed 6 months ago
LGTM, @fcfangcc could you add a comment explaining what is happening?
@jsturtevant You mean to add a comment explaining in the source code?
Yes, essentially describing a summary of https://github.com/containerd/rust-extensions/pull/264#discussion_r1581426817. We had to dive in and dig around to figure out what was going on. It would be nice to leave a quick explanation for the next person to point out what seems like a strange set up (setting up with http/https but actually ignoring that value all together and using our own logic to connect).
fixed #261
In tonic, if uri startwith "https", will use tls connect.
https://github.com/hyperium/tonic/blob/eeb3268f71ae5d1107c937392389db63d8f721fb/tonic/src/transport/service/connector.rs#L74-L90
Just change uri prefix "http" can skip this logic.Like: https://github.com/hyperium/tonic/blob/eeb3268f71ae5d1107c937392389db63d8f721fb/examples/src/uds/client.rs#L19