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

fix: fix transaction route on multi host #266

Merged
merged 4 commits into from
Sep 5, 2024

Conversation

ZhiHanZ
Copy link
Collaborator

@ZhiHanZ ZhiHanZ commented Sep 5, 2024

No description provided.


public static String uriRouteHint(String URI) {
// Encode the URI using Base64
String encodedUri = Base64.getEncoder().encodeToString(URI.getBytes());
Copy link
Member

Choose a reason for hiding this comment

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

a xxhash might be possible here, might allow making this route hint shorter.

(not needed in this pr, could pick it up if one day some people complains it's too long qwq)

return false;
}

private List<URI> parseURI(List<DiscoveryNode> nodes) throws SQLException {
Copy link
Member

Choose a reason for hiding this comment

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

Add some UT for discoverUris and parseURI function?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I will write another PR fully test on those auto discovery related functions.

@ZhiHanZ ZhiHanZ requested a review from flaneur2020 September 5, 2024 07:15
Copy link
Member

@flaneur2020 flaneur2020 left a comment

Choose a reason for hiding this comment

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

LGTM, @hantmac PTAL

Copy link
Member

@hantmac hantmac left a comment

Choose a reason for hiding this comment

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

LGTM 🚀

@ZhiHanZ ZhiHanZ merged commit 8f0b4d8 into databendlabs:main Sep 5, 2024
2 checks passed
cdmikechen pushed a commit to cdmikechen/databend-jdbc that referenced this pull request Oct 29, 2024
* fix: fix transaction route on multi host

* chore: fix flaky cluster key

* chore: ignore useless code

* chore: add more comment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants