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

[CP] Patch getscanners to hbase_2.x #143

Open
wants to merge 1 commit into
base: hbase_2.0
Choose a base branch
from

Conversation

JackShi148
Copy link
Contributor

Summary

Patch getscanners from hbase_1.x to hbase_2.x, to expose the tablet interface for accelerating scan.

Solution Description

@@ -1086,6 +1087,92 @@ public ResultScanner call() throws IOException {
return executeServerCallable(serverCallable);
}

public List<ResultScanner> getScanners(final Scan scan) throws IOException {

if (scan.getFamilyMap().keySet().isEmpty()) {
Copy link
Contributor

Choose a reason for hiding this comment

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

这块为什么还要写个空的body在这。直接if (!scan.getFamilyMap().keySet().isEmpty())好点吧

filter = buildObHTableFilter(scan.getFilter(), scan.getTimeRange(),
scan.getMaxVersions(), columnFilters);
obTableQuery = buildObTableQuery(filter, scan);
List<ResultScanner> resultScanners = new ArrayList<ResultScanner>();
Copy link
Contributor

Choose a reason for hiding this comment

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

这种单cf和多cf一样的代码可以抽到外层定义

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.

2 participants