David Ribeiro Alves has submitted this change and it was merged.

Change subject: Add a generic retriable rpc class
......................................................................


Add a generic retriable rpc class

This patch adds a new, generic, class for retriable Rpcs: RetriableRpc.
This class will handle retry logic, such as setting id/sequence numbers on
the rpc header, as well as number of attempts.

Derived classes of RetriableRpc no longer have to deal with logic regarding
replica selection, proxy initialization or retrying. They just have to 
implement:
Try() - Actually sends the rpc to a server.
AnalyzeResponse() - Buckets the response into a few, common, categories.
Finish() - Handle (final) success or failure.

This also refactors WriteRpc to use the new class.

Change-Id: Iaa58bdc5656a5d4d9172885a67363f74718a0c8e
Reviewed-on: http://gerrit.cloudera.org:8080/3064
Tested-by: Kudu Jenkins
Reviewed-by: Adar Dembo <a...@cloudera.com>
---
M src/kudu/client/batcher.cc
A src/kudu/rpc/retriable_rpc.h
2 files changed, 213 insertions(+), 114 deletions(-)

Approvals:
  Adar Dembo: Looks good to me, approved
  Kudu Jenkins: Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/3064
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Iaa58bdc5656a5d4d9172885a67363f74718a0c8e
Gerrit-PatchSet: 13
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: David Ribeiro Alves <david.al...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <a...@cloudera.com>
Gerrit-Reviewer: David Ribeiro Alves <david.al...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <t...@apache.org>

Reply via email to