Will Berkeley has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/12138 )
Change subject: Support location awareness in READ_CLOSEST for the C++ client ...................................................................... Support location awareness in READ_CLOSEST for the C++ client Previously, in READ_CLOSEST, the C++ client would choose to read from a local tablet server if possible and otherwise pick a random replica. This changes and enhances READ_CLOSEST mode to work as follows: 1. If there is a local server, use it. If there are multiple local servers, choose one at random. 2. If there is a server in the same location as the client, use it. If there are multiple servers in the same location, choose one at random. 3. Otherwise, choose a server at random. This is not a breaking change, as in the absence of locations the behavior is consistent with what was documented before, which was only that a local server would be chosen if possible, else a random server. Change-Id: I2c6bcc7479c5cf2e17cb6e368ca89a1eb7f21713 Reviewed-on: http://gerrit.cloudera.org:8080/12138 Reviewed-by: Adar Dembo <[email protected]> Tested-by: Kudu Jenkins Reviewed-by: Grant Henke <[email protected]> Reviewed-by: Alexey Serbin <[email protected]> --- M src/kudu/client/client-internal.cc M src/kudu/client/client-internal.h M src/kudu/client/client.cc M src/kudu/client/client.h M src/kudu/client/meta_cache.cc M src/kudu/client/meta_cache.h M src/kudu/integration-tests/location_assignment-itest.cc 7 files changed, 156 insertions(+), 24 deletions(-) Approvals: Adar Dembo: Looks good to me, but someone else must approve Kudu Jenkins: Verified Grant Henke: Looks good to me, but someone else must approve Alexey Serbin: Looks good to me, approved -- To view, visit http://gerrit.cloudera.org:8080/12138 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: merged Gerrit-Change-Id: I2c6bcc7479c5cf2e17cb6e368ca89a1eb7f21713 Gerrit-Change-Number: 12138 Gerrit-PatchSet: 10 Gerrit-Owner: Will Berkeley <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Alexey Serbin <[email protected]> Gerrit-Reviewer: Grant Henke <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Reviewer: Tidy Bot (241) Gerrit-Reviewer: Will Berkeley <[email protected]>
