Closed DEvil0000 closed 9 years ago
I wouldn't do that. The boost asio library already encapsulates the name resolving as a service and the library code just uses it. Why should we wrap another service around it. In my opinion, a Client
implementation should not do name resolving. It should just use the Connection
objects for that (also for fetching the meta data).
I think it would make sense to extract the resolver code to have some kind of resolver/lookup service. At the moment it is used to establish the connection but it could also be useful to map a
host:port
string to aConnection
or Broker UID. And in this case we need to resolve the thing in theClient
and not theConnection
.Do you see a problem with this?