{"action":"created","comment":{"url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/comments/49037338","id":49037338,"diff_hunk":"@@ -24,32 +26,141 @@ static inline std::string to_upper(const std::string& in) {\n     std::string out;\n     out.reserve( in.size() );\n     for(std::size_t i=0; i<in.length(); i++ ) {\n-        out += char( toupper(in[i]) );       \n+        out += char( toupper(in[i]) );\n     }\n     return out;\n }\n \n+static inline void my_assert(bool b, const char *msg) {\n+    if(!b) {\n+        DEBUGERROR(msg) std::cerr << \"[ERROR] redis::cluster: \"<< msg << std::endl;","path":"redis_cluster.cpp","position":36,"original_position":36,"commit_id":"75aff2b0c2ce3c5a4159d2fab66537de175e7b20","original_commit_id":"75aff2b0c2ce3c5a4159d2fab66537de175e7b20","user":{"login":"anticpp","id":5907797,"avatar_url":"https://avatars.githubusercontent.com/u/5907797?v=3","gravatar_id":"","url":"https://api.github.com/users/anticpp","html_url":"https://github.com/anticpp","followers_url":"https://api.github.com/users/anticpp/followers","following_url":"https://api.github.com/users/anticpp/following{/other_user}","gists_url":"https://api.github.com/users/anticpp/gists{/gist_id}","starred_url":"https://api.github.com/users/anticpp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anticpp/subscriptions","organizations_url":"https://api.github.com/users/anticpp/orgs","repos_url":"https://api.github.com/users/anticpp/repos","events_url":"https://api.github.com/users/anticpp/events{/privacy}","received_events_url":"https://api.github.com/users/anticpp/received_events","type":"User","site_admin":false},"body":"这里没看懂，为什么要输出两次错误信息","created_at":"2016-01-07T02:51:17Z","updated_at":"2016-01-07T02:51:17Z","html_url":"https://github.com/anticpp/redis-c-cluster/pull/1#discussion_r49037338","pull_request_url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/comments/49037338"},"html":{"href":"https://github.com/anticpp/redis-c-cluster/pull/1#discussion_r49037338"},"pull_request":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1","id":54948799,"html_url":"https://github.com/anticpp/redis-c-cluster/pull/1","diff_url":"https://github.com/anticpp/redis-c-cluster/pull/1.diff","patch_url":"https://github.com/anticpp/redis-c-cluster/pull/1.patch","issue_url":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/1","number":1,"state":"open","locked":false,"title":"Improve","user":{"login":"derbanfee","id":16462606,"avatar_url":"https://avatars.githubusercontent.com/u/16462606?v=3","gravatar_id":"","url":"https://api.github.com/users/derbanfee","html_url":"https://github.com/derbanfee","followers_url":"https://api.github.com/users/derbanfee/followers","following_url":"https://api.github.com/users/derbanfee/following{/other_user}","gists_url":"https://api.github.com/users/derbanfee/gists{/gist_id}","starred_url":"https://api.github.com/users/derbanfee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/derbanfee/subscriptions","organizations_url":"https://api.github.com/users/derbanfee/orgs","repos_url":"https://api.github.com/users/derbanfee/repos","events_url":"https://api.github.com/users/derbanfee/events{/privacy}","received_events_url":"https://api.github.com/users/derbanfee/received_events","type":"User","site_admin":false},"body":"support connection pools and multi-threads","created_at":"2016-01-04T07:18:55Z","updated_at":"2016-01-07T02:51:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ff3cbb5f7b89132e50580016678e5bda45674e2d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1/commits","review_comments_url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1/comments","review_comment_url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/comments{/number}","comments_url":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/1/comments","statuses_url":"https://api.github.com/repos/anticpp/redis-c-cluster/statuses/75aff2b0c2ce3c5a4159d2fab66537de175e7b20","head":{"label":"derbanfee:improve","ref":"improve","sha":"75aff2b0c2ce3c5a4159d2fab66537de175e7b20","user":{"login":"derbanfee","id":16462606,"avatar_url":"https://avatars.githubusercontent.com/u/16462606?v=3","gravatar_id":"","url":"https://api.github.com/users/derbanfee","html_url":"https://github.com/derbanfee","followers_url":"https://api.github.com/users/derbanfee/followers","following_url":"https://api.github.com/users/derbanfee/following{/other_user}","gists_url":"https://api.github.com/users/derbanfee/gists{/gist_id}","starred_url":"https://api.github.com/users/derbanfee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/derbanfee/subscriptions","organizations_url":"https://api.github.com/users/derbanfee/orgs","repos_url":"https://api.github.com/users/derbanfee/repos","events_url":"https://api.github.com/users/derbanfee/events{/privacy}","received_events_url":"https://api.github.com/users/derbanfee/received_events","type":"User","site_admin":false},"repo":{"id":48731291,"name":"redis-c-cluster","full_name":"derbanfee/redis-c-cluster","owner":{"login":"derbanfee","id":16462606,"avatar_url":"https://avatars.githubusercontent.com/u/16462606?v=3","gravatar_id":"","url":"https://api.github.com/users/derbanfee","html_url":"https://github.com/derbanfee","followers_url":"https://api.github.com/users/derbanfee/followers","following_url":"https://api.github.com/users/derbanfee/following{/other_user}","gists_url":"https://api.github.com/users/derbanfee/gists{/gist_id}","starred_url":"https://api.github.com/users/derbanfee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/derbanfee/subscriptions","organizations_url":"https://api.github.com/users/derbanfee/orgs","repos_url":"https://api.github.com/users/derbanfee/repos","events_url":"https://api.github.com/users/derbanfee/events{/privacy}","received_events_url":"https://api.github.com/users/derbanfee/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/derbanfee/redis-c-cluster","description":"A c++ client library for redis cluster.","fork":true,"url":"https://api.github.com/repos/derbanfee/redis-c-cluster","forks_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/forks","keys_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/keys{/key_id}","collaborators_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/teams","hooks_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/hooks","issue_events_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/issues/events{/number}","events_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/events","assignees_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/assignees{/user}","branches_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/branches{/branch}","tags_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/tags","blobs_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/git/refs{/sha}","trees_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/git/trees{/sha}","statuses_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/statuses/{sha}","languages_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/languages","stargazers_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/stargazers","contributors_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/contributors","subscribers_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/subscribers","subscription_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/subscription","commits_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/commits{/sha}","git_commits_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/git/commits{/sha}","comments_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/comments{/number}","issue_comment_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/issues/comments{/number}","contents_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/contents/{+path}","compare_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/compare/{base}...{head}","merges_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/merges","archive_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/downloads","issues_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/issues{/number}","pulls_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/pulls{/number}","milestones_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/milestones{/number}","notifications_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/labels{/name}","releases_url":"https://api.github.com/repos/derbanfee/redis-c-cluster/releases{/id}","created_at":"2015-12-29T06:22:21Z","updated_at":"2015-12-29T06:22:22Z","pushed_at":"2016-01-06T12:24:46Z","git_url":"git://github.com/derbanfee/redis-c-cluster.git","ssh_url":"git@github.com:derbanfee/redis-c-cluster.git","clone_url":"https://github.com/derbanfee/redis-c-cluster.git","svn_url":"https://github.com/derbanfee/redis-c-cluster","homepage":null,"size":45,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"anticpp:improve","ref":"improve","sha":"09dd30cf37cafd5f9de7b3710224f38974a0d72d","user":{"login":"anticpp","id":5907797,"avatar_url":"https://avatars.githubusercontent.com/u/5907797?v=3","gravatar_id":"","url":"https://api.github.com/users/anticpp","html_url":"https://github.com/anticpp","followers_url":"https://api.github.com/users/anticpp/followers","following_url":"https://api.github.com/users/anticpp/following{/other_user}","gists_url":"https://api.github.com/users/anticpp/gists{/gist_id}","starred_url":"https://api.github.com/users/anticpp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anticpp/subscriptions","organizations_url":"https://api.github.com/users/anticpp/orgs","repos_url":"https://api.github.com/users/anticpp/repos","events_url":"https://api.github.com/users/anticpp/events{/privacy}","received_events_url":"https://api.github.com/users/anticpp/received_events","type":"User","site_admin":false},"repo":{"id":38039308,"name":"redis-c-cluster","full_name":"anticpp/redis-c-cluster","owner":{"login":"anticpp","id":5907797,"avatar_url":"https://avatars.githubusercontent.com/u/5907797?v=3","gravatar_id":"","url":"https://api.github.com/users/anticpp","html_url":"https://github.com/anticpp","followers_url":"https://api.github.com/users/anticpp/followers","following_url":"https://api.github.com/users/anticpp/following{/other_user}","gists_url":"https://api.github.com/users/anticpp/gists{/gist_id}","starred_url":"https://api.github.com/users/anticpp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anticpp/subscriptions","organizations_url":"https://api.github.com/users/anticpp/orgs","repos_url":"https://api.github.com/users/anticpp/repos","events_url":"https://api.github.com/users/anticpp/events{/privacy}","received_events_url":"https://api.github.com/users/anticpp/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/anticpp/redis-c-cluster","description":"A c++ client library for redis cluster.","fork":false,"url":"https://api.github.com/repos/anticpp/redis-c-cluster","forks_url":"https://api.github.com/repos/anticpp/redis-c-cluster/forks","keys_url":"https://api.github.com/repos/anticpp/redis-c-cluster/keys{/key_id}","collaborators_url":"https://api.github.com/repos/anticpp/redis-c-cluster/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/anticpp/redis-c-cluster/teams","hooks_url":"https://api.github.com/repos/anticpp/redis-c-cluster/hooks","issue_events_url":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/events{/number}","events_url":"https://api.github.com/repos/anticpp/redis-c-cluster/events","assignees_url":"https://api.github.com/repos/anticpp/redis-c-cluster/assignees{/user}","branches_url":"https://api.github.com/repos/anticpp/redis-c-cluster/branches{/branch}","tags_url":"https://api.github.com/repos/anticpp/redis-c-cluster/tags","blobs_url":"https://api.github.com/repos/anticpp/redis-c-cluster/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/anticpp/redis-c-cluster/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/anticpp/redis-c-cluster/git/refs{/sha}","trees_url":"https://api.github.com/repos/anticpp/redis-c-cluster/git/trees{/sha}","statuses_url":"https://api.github.com/repos/anticpp/redis-c-cluster/statuses/{sha}","languages_url":"https://api.github.com/repos/anticpp/redis-c-cluster/languages","stargazers_url":"https://api.github.com/repos/anticpp/redis-c-cluster/stargazers","contributors_url":"https://api.github.com/repos/anticpp/redis-c-cluster/contributors","subscribers_url":"https://api.github.com/repos/anticpp/redis-c-cluster/subscribers","subscription_url":"https://api.github.com/repos/anticpp/redis-c-cluster/subscription","commits_url":"https://api.github.com/repos/anticpp/redis-c-cluster/commits{/sha}","git_commits_url":"https://api.github.com/repos/anticpp/redis-c-cluster/git/commits{/sha}","comments_url":"https://api.github.com/repos/anticpp/redis-c-cluster/comments{/number}","issue_comment_url":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/comments{/number}","contents_url":"https://api.github.com/repos/anticpp/redis-c-cluster/contents/{+path}","compare_url":"https://api.github.com/repos/anticpp/redis-c-cluster/compare/{base}...{head}","merges_url":"https://api.github.com/repos/anticpp/redis-c-cluster/merges","archive_url":"https://api.github.com/repos/anticpp/redis-c-cluster/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/anticpp/redis-c-cluster/downloads","issues_url":"https://api.github.com/repos/anticpp/redis-c-cluster/issues{/number}","pulls_url":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls{/number}","milestones_url":"https://api.github.com/repos/anticpp/redis-c-cluster/milestones{/number}","notifications_url":"https://api.github.com/repos/anticpp/redis-c-cluster/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/anticpp/redis-c-cluster/labels{/name}","releases_url":"https://api.github.com/repos/anticpp/redis-c-cluster/releases{/id}","created_at":"2015-06-25T09:05:01Z","updated_at":"2016-01-04T07:16:44Z","pushed_at":"2016-01-06T12:24:47Z","git_url":"git://github.com/anticpp/redis-c-cluster.git","ssh_url":"git@github.com:anticpp/redis-c-cluster.git","clone_url":"https://github.com/anticpp/redis-c-cluster.git","svn_url":"https://github.com/anticpp/redis-c-cluster","homepage":null,"size":32,"stargazers_count":2,"watchers_count":2,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":1,"forks":1,"open_issues":1,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1"},"html":{"href":"https://github.com/anticpp/redis-c-cluster/pull/1"},"issue":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/1"},"comments":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/anticpp/redis-c-cluster/statuses/75aff2b0c2ce3c5a4159d2fab66537de175e7b20"}}}}