You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kudu.apache.org by "Jean-Daniel Cryans (Code Review)" <ge...@cloudera.org> on 2016/04/21 02:07:51 UTC
[kudu-CR] KUDU-1364. Don't clear the cache when a server disconnect
Hello Kudu Jenkins,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/2449
to look at the new patch set (#3).
Change subject: KUDU-1364. Don't clear the cache when a server disconnect
......................................................................
KUDU-1364. Don't clear the cache when a server disconnect
Folks seem to agree that, in the Java client, clearing the cache when a
server gets disconnected (for any reason) is not a good idea.
This patch does major surgery on how we handle cached TabletClients.
We now always keep them in RemoteTablet, and do our best to remember
if they were a leader. Only the ip2client is being removed from. We
now rely on the TabletClient's 'dead' attribute to know if a
connection is stale and needs to be re-established.
Not clear if client2tablets really needs to be removed from, and when.
We'll probably only remove from it in the future when we support
dropping ranges.
The patch also introduces a new integration test for the client. It's
still super basic but gives more confidence in the change.
It also fixes a dumb bug that was killing scanners too soon if there
was a disconnection.
Change-Id: I8606bfcedb09af57b66ba0f065067f0f3335a4a8
---
M java/kudu-client/src/main/java/org/kududb/client/AsyncKuduClient.java
M java/kudu-client/src/main/java/org/kududb/client/AsyncKuduScanner.java
M java/kudu-client/src/main/java/org/kududb/client/TabletClient.java
A java/kudu-client/src/test/java/org/kududb/client/ITClient.java
M java/kudu-client/src/test/java/org/kududb/client/TestAsyncKuduClient.java
5 files changed, 577 insertions(+), 60 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/49/2449/3
--
To view, visit http://gerrit.cloudera.org:8080/2449
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I8606bfcedb09af57b66ba0f065067f0f3335a4a8
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Jean-Daniel Cryans
Gerrit-Reviewer: Kudu Jenkins