You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Mario Emmenlauer (Jira)" <ji...@apache.org> on 2020/04/20 15:50:00 UTC
[jira] [Commented] (THRIFT-5178) THttpClient should work without
specifying host
[ https://issues.apache.org/jira/browse/THRIFT-5178?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17087874#comment-17087874 ]
Mario Emmenlauer commented on THRIFT-5178:
------------------------------------------
The PR for this issue adds a new default for the HTTP path. It sets path = "service". This is not strictly required, but mitigates issue THRIFT-5180 where a path name is _required_ for Unix domain sockets.
In my personal opinion, it is also more useful to have a default path than not to have a path. After reading https://www.w3.org/Protocols/rfc2616/rfc2616-sec5.html I'm under the impression that the HTTP/1.1 protocol requires a Request-URI.
> THttpClient should work without specifying host
> -----------------------------------------------
>
> Key: THRIFT-5178
> URL: https://issues.apache.org/jira/browse/THRIFT-5178
> Project: Thrift
> Issue Type: Improvement
> Components: C++ - Library
> Affects Versions: 0.13.0
> Reporter: Mario Emmenlauer
> Assignee: Mario Emmenlauer
> Priority: Trivial
>
> The [constructors for THttpClient|https://github.com/apache/thrift/blob/9e864d57026b4905862108418ba9482892fb1f65/lib/cpp/src/thrift/transport/THttpClient.h#L31] require specifying a `host`. However not all supported socket types would require a host. I.e. when using a Unix domain socket, the `host` property does not convey additional information, as the socket only works on localhost. The constructor of the socket (the underlying transport) does not require host.
> It would be nice if there was a constructor that avoids host (making it optional).
--
This message was sent by Atlassian Jira
(v8.3.4#803005)