-
Notifications
You must be signed in to change notification settings - Fork 894
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
Add logs for ensemble select failed #3779
Changes from 4 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -519,9 +519,9 @@ public BookieNode selectFromNetworkLocation( | |
networkLoc, excludeBookies); | ||
throw e; | ||
} | ||
LOG.warn("Failed to choose a bookie from {} : " | ||
+ "excluded {}, fallback to choose bookie randomly from the cluster.", | ||
networkLoc, excludeBookies); | ||
LOG.warn("Failed to choose a bookie from {} : leaves {}, excluded bookies {}, " | ||
+ "current ensemble {}, fallback to choose bookie randomly from the cluster.", | ||
networkLoc, topology.getLeaves(networkLoc), excludeBookies, ensemble); | ||
// randomly choose one from whole cluster, ignore the provided predicate. | ||
return selectRandom(1, excludeBookies, predicate, ensemble).get(0); | ||
} | ||
|
@@ -544,6 +544,9 @@ public BookieNode selectFromNetworkLocation(String networkLoc, | |
* the whole cluster and exclude the racks specified at | ||
* <tt>excludeRacks</tt>. | ||
*/ | ||
LOG.warn("Failed to choose a bookie node from {} : leaves {}, exclude Bookies {}, " | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The Failed to choose a bookie from {} : leaves -> Failed to choose a bookie from network location {}, the network location corresponding bookies {} There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. make sense |
||
+ "current ensemble {}, fallback to choose bookie randomly from the cluster.", | ||
networkLoc, topology.getLeaves(networkLoc), excludeBookies, ensemble); | ||
return selectFromNetworkLocation(excludeRacks, excludeBookies, predicate, ensemble, fallbackToRandom); | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
leaves
may confuse the user.Failed to choose a bookie from {} : leaves -> Failed to choose a bookie from network location {}, the network location corresponding bookies {}