-
Notifications
You must be signed in to change notification settings - Fork 24
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 return_one_result flag not return one result #110
Conversation
if (returnOneResult) { | ||
if (results[0] == null) { | ||
results[0] = new ObTableOperationResult(); | ||
} |
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.
need to accumulate affected_rows when the table operation spans two or more tablet
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.
done
} | ||
ObTableOperationType lastType = operations.get(0).getOperationType(); | ||
if (returnOneResult | ||
&& !(batchOperation.isSameType() && (lastType == ObTableOperationType.INSERT |
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.
can we move this defensive code to the interface layer, which will be more readable?
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.
done
* 增加same_property_names判断 (#79) * properties name ignor case --------- Co-authored-by: wumengjie.wmj <[email protected]> * support put operation (#80) * add option flag, batch operations can return one res (#94) * fix test case, in return one result (#97) * add option flag, batch operations can return one res * fix return one result test * add tests (#103) * support batch put (#107) * fix batch put use correct api (#108) * support batch put * fix batch put use put method * atomic can across partition * [Feat] batchOperation support LSOp (#105) * [Feat] support LS batch routing * [Feat] single operation adapt to ObTableLSOp * [Test] add test for LS batch * [Enhancement] add get operation test for LsOp and fix bugs * [Test] add test cases for ObTableLSOp * [Test] add batch put test for ObTableLSOp * [Fix] add defensive code to disallow mix checkAndInsUp and other types operation * [OBKV] ObTableLsOp adapt to returnOneResult * [Fix] modify accord to review * fix return_one_result flag not return one result (#110) * fix return_one_result flag not return one result * fix review * [Fix] adapt to lob-related table object type (#113) * [Fix] adapt to lob-related table object type * [Fix] set ObLsOp tableName for ODP mode * Fix prv tenantid always 1 (#114) * fix prv_tenantid always 1 * add BatchGet test case * [Fix] isSamePropertiesNames flag is wrong in ObTableTabletOp (#118) * fix review comment --------- Co-authored-by: eemjwu <[email protected]> Co-authored-by: wumengjie.wmj <[email protected]> Co-authored-by: xiaoai <[email protected]> Co-authored-by: Shen Yunlong <[email protected]>
Summary
fix return_one_result flag not return one result
Solution Description
When returning the package, merge the results of each partition.