-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement http proxy task #378
Conversation
src/factory/HttpTaskImpl.cc
Outdated
|
||
using namespace protocol; | ||
|
||
#define HTTP_KEEPALIVE_DEFAULT (60 * 1000) | ||
#define HTTP_KEEPALIVE_MAX (300 * 1000) | ||
|
||
static int __encode_auth(const char *p, std::string& auth) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个移动到下面吧。毕竟和非proxy的情况没有关系。
src/factory/HttpTaskImpl.cc
Outdated
|
||
BIO_free_all(b64); | ||
return 0; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
应该有个空行?
@@ -56,11 +123,11 @@ class ComplexHttpTask : public WFComplexClientTask<HttpRequest, HttpResponse> | |||
virtual void init_failed(); | |||
virtual bool finish_once(); | |||
|
|||
private: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
再写一次protected吧。
src/factory/HttpTaskImpl.cc
Outdated
return false; | ||
} | ||
|
||
if(user_uri_.scheme && strcasecmp(user_uri_.scheme, "http") == 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
格式问题。两个if后面的空格没了。
done |
we can use http proxy when visit http(s) server now.