hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Enis Soztutar (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-17576) [C++] Implement request retry mechanism over RPC for Multi calls.
Date Wed, 03 May 2017 23:17:04 GMT

    [ https://issues.apache.org/jira/browse/HBASE-17576?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15995881#comment-15995881

Enis Soztutar commented on HBASE-17576:

Doing these kind of aliases is not good in a header file. They should at least be in the hbase
namespace. Please look into whether you can move them to the .cc file or not. 
+using SharedResult = std::shared_ptr<Result>;
+using FutureResult = Future<SharedResult>;
+using PromiseResult = Promise<SharedResult>;
+using MultiResult = std::unique_ptr<std::vector<FutureResult>>;
+using Errors = std::shared_ptr<std::vector<ThrowableWithExtraContext>>;

- Remove this: 
+  // typedef BatchCallerBuilder GenenericThisType;

- Rename the name of the test to "MultiGets": 
+TEST_F(ClientTest, PutGets) {

- There was an earlier comment about not iterating through these maps, because these maps
are supposed to be hash maps, and this one in particular is already keyed by server name.
Please do not iterate through the whole map like this: 
+            for (auto itr = actions_by_server.begin(); itr != actions_by_server.end(); ++itr)
+              ServerNameEquals server_name_equals;

- And as we have discussed offline, we cannot be blocking on the location lookup, or in {{GetMultiResponse()}}
by calling {{.get()}} on Futures. This defeats the whole purpose of the async flow. 

- Nit: you can just do a normal iteration here rather than using std::for_each(): 
+    std::for_each(
+        std::begin(region_requests), std::end(region_requests),
+        [&regions](const std::vector<std::shared_ptr<RegionRequest>>::value_type
&region_request) {
+          regions += region_request->region_location()->region_name() + ", ";
+        });

> [C++] Implement request retry mechanism over RPC for Multi calls.
> -----------------------------------------------------------------
>                 Key: HBASE-17576
>                 URL: https://issues.apache.org/jira/browse/HBASE-17576
>             Project: HBase
>          Issue Type: Sub-task
>            Reporter: Sudeep Sunthankar
>            Assignee: Sudeep Sunthankar
>         Attachments: HBASE-17576.HBASE-14850.v10.patch, HBASE-17576.HBASE-14850.v1.patch,
HBASE-17576.HBASE-14850.v2.patch, HBASE-17576.HBASE-14850.v3.patch, HBASE-17576.HBASE-14850.v4.patch,
HBASE-17576.HBASE-14850.v5.patch, HBASE-17576.HBASE-14850.v6.patch, HBASE-17576.HBASE-14850.v7.patch,
HBASE-17576.HBASE-14850.v8.patch, HBASE-17576.HBASE-14850.v9.patch
> This work is based on top of HBASE-17465. Multi Calls will be based on this.

This message was sent by Atlassian JIRA

View raw message