Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CURATOR-349] Trace the session id even when it is disconnected #172

Merged
merged 1 commit into from Nov 10, 2016

Conversation

lvfangmin
Copy link
Contributor

The default session id inside ZooKeeper is 0, we should keep consistent with it in tracker.

}
} catch (Exception e) {
// Ignore the exception
long sessionId = 0;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why did we lose the isConnected() check?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also want to track the sessionId when the connection timed-out happened, also it would be useful if we can know what's the disconnected session id when the create/setData/getData is called.

Any concern of removing the isConnected() check?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My concern is that zooKeeper.getZooKeeper() can cause a new connection to get started. I'm not sure that that kind of side-effect is expected. If there is no current connection or the connection is in error somehow, zooKeeper.getZooKeeper() will call HandleHolder.closeAndReset().

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Randgalt, here we're calling the HandleHolder.getZookeeper() directly, so it won't call closeAndReset(), please correct me if I missed anything.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I think you're right. I think I can accept this.

@lvfangmin lvfangmin changed the title [CURATOR-349] Use zero as the default session id to keep consistent with ZooKeeper [CURATOR-349] Trace the session id even when it is disconnected Nov 2, 2016
@lvfangmin
Copy link
Contributor Author

(Not related with this diff)
@Randgalt , do we have the schedule of Curator release, are we still blocked by ZOOKEEPER-1525?

The ZOOKEEPER-1525 looks good to me except the new additional parameters concern, if we can refactor that a bit, I'll add a +1 and ask Ben (one of the ZooKeeper committer, also my team member) to accelerate the review process and accept it.

@lvfangmin
Copy link
Contributor Author

Btw, I also like to get this in the next release :)

@asfgit asfgit merged commit e9bfb43 into apache:master Nov 10, 2016
@Randgalt
Copy link
Member

I'll start working on a release

@lvfangmin
Copy link
Contributor Author

Thanks @Randgalt, please let me know when the new release is published 👍

@lvfangmin
Copy link
Contributor Author

Hi @Randgalt, hope you have a great weekend :)
Sorry about this, but could you please give me some updates about the release, so I can plan this weeks' work about whether I can start migrating the internal projects to Curator or not.

@Randgalt
Copy link
Member

@lvfangmin do you subscribe to dev@curator? We released this morning and an email was sent to that list. So, the bits are available now.

@lvfangmin
Copy link
Contributor Author

Ah, just saw it, thanks @Randgalt!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants