victorunique opened a new pull request #17419:
URL: https://github.com/apache/flink/pull/17419
## What is the purpose of the change
In FLINK-9373, we introduced RocksIteratorWrapper which was a wrapper around
RocksIterator to check the iterator status for all the methods. At that time,
it was required because the iterator may pass the blocks or files it had
difficulties in reading (because of IO errors, data corruptions, or other
issues) and continue with the next available keys. The status flag may not be
OK, even if the iterator is valid.
However, the above behaviour changed after 3810 was merged on May 17, 2018:
- If the iterator is valid, the status() is guaranteed to be OK;
- If the iterator is not valid, there are two possibilities:
1) We have reached the end of the data. And in this case, status() is OK;
2) There is an error. In this case, status() is not OK;
More information can be found here:
https://github.com/facebook/rocksdb/wiki/Iterator#error-handling
## Brief change log
- *Remove all the status() calls from existing methods*
- *Add status() check when the iterator is invalid (as per the best
practice in the rocksdb wiki above)*
- *Update the comments of RocksIteratorWrapper for this change*
## Verifying this change
This change is a trivial rework / code cleanup without any test coverage.
## Does this pull request potentially affect one of the following parts:
- Dependencies (does it add or upgrade a dependency): (no)
- The public API, i.e., is any changed class annotated with
`@Public(Evolving)`: (no)
- The serializers: (no)
- The runtime per-record code paths (performance sensitive): (no)
- Anything that affects deployment or recovery: JobManager (and its
components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (no)
- The S3 file system connector: (no)
## Documentation
- Does this pull request introduce a new feature? (no)
- If yes, how is the feature documented? (not applicable)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]