szetszwo commented on code in PR #4104:
URL: https://github.com/apache/ozone/pull/4104#discussion_r1062190515
##########
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/storage/RatisBlockOutputStream.java:
##########
@@ -126,4 +128,16 @@ void waitOnFlushFutures() throws InterruptedException,
ExecutionException {
void cleanup() {
commitWatcher.cleanup();
}
+
+ @Override
+ public void hflush() throws IOException {
+ hsync();
+ }
+
+ @Override
+ public void hsync() throws IOException {
+ if (!isClosed()) {
Review Comment:
> ... here is the place we need to implement to notify to OM, here is a
hsync call from app, we need to update the block info along with the so far
committed content right? ...
This is a lower level method (the commit here is Ratis commit, not OM
commit).
Apps use OzoneOutputStream (or OzoneFSOutputStream). OzoneOutputStream
contains KeyOutputStream (which could be wrapped by a CryptoOutputStream). The
right place to update OM length is `KeyOutputStream.hsync()`. Just have filed
HDDS-7724 and revised the TODO in `KeyOutputStream.hsync`.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]