Description
In prepare phase of write path, some row data may have some errors, like missing a non-nullable field value, then the whole batch will fail, even if the other rows have no errors.
It's a kind of waste, we should take best effect for the batch as how it work in apply phase, partial rows errors should not fail the whole batch operation.
For example, these code can be improved:
https://github.com/apache/kudu/blob/master/src/kudu/common/row_operations.cc#L387
if (PREDICT_FALSE(!(col.is_nullable() || col.has_write_default()))) { // TODO: change this to return per-row errors. Otherwise if one row in a batch // is missing a field for some reason, the whole batch will fail. return Status::InvalidArgument("No value provided for required column", col.ToString()); }
Attachments
Issue Links
- duplicates
-
KUDU-2625 Unexpected behavior of WriteBatch wrt rows violating schema constraints
- Resolved