Yifan Zhang has submitted this change and it was merged. ( 
http://gerrit.cloudera.org:8080/15444 )

Change subject: [java] fix bug in getClosestServerInfo code
......................................................................

[java] fix bug in getClosestServerInfo code

When client handles tablet not found error, it removes the tablet server
from the RemoteTablet's locations. If all tablet servers are removed,
the code in getClosestServerInfo will throw a division by zero exception.
This patch fixed it and added a test to verify getClosestServerInfo
returns null when all locations of a tablet are invalid.

Change-Id: Ib4dc471b5044ea4b5bd6202ccd2a707d6e229ea0
Reviewed-on: http://gerrit.cloudera.org:8080/15444
Reviewed-by: Adar Dembo <[email protected]>
Tested-by: Kudu Jenkins
---
M java/kudu-client/src/main/java/org/apache/kudu/client/RemoteTablet.java
M java/kudu-client/src/test/java/org/apache/kudu/client/TestRemoteTablet.java
2 files changed, 16 insertions(+), 0 deletions(-)

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

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

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib4dc471b5044ea4b5bd6202ccd2a707d6e229ea0
Gerrit-Change-Number: 15444
Gerrit-PatchSet: 3
Gerrit-Owner: Yifan Zhang <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Yifan Zhang <[email protected]>

Reply via email to