-
Notifications
You must be signed in to change notification settings - Fork 82
Consider renaming Dispatch::{In, Out} #120
Comments
In general, |
I think your points are totally valid, and of course, an issue like this will always have a subjective component. One thing to consider though is that |
To clarify, I don't think anybody likes the |
I was going to comment that maybe the types should be named Given that |
It looks like tokio-core is going with Given that, how about |
So, the "obvious" naming would be to match
|
This was sort of discussed in tokio-rs/tokio-core#135 née #64, but it's for Dispatch::{In, Out} instead.
I think that the current use of In and Out are unintuitive, and should be switched. The current mental model is socket-centric, In is what goes into a socket, and Out is what comes out of it. However, I personally and I suspect others, when writing network applications, think from the point of view of the client or the server.
The In thing is the thing that is coming from over the network, and the Out thing is the thing that is going out over the network. So a server takes requests in and sends responses out, and a client sends requests out and takes responses in.
I would also prefer the names Incoming and Outgoing instead of In and Out, just to be a little more explicit.
The text was updated successfully, but these errors were encountered: