You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "ashishkumar50 (via GitHub)" <gi...@apache.org> on 2024/12/18 12:33:04 UTC
[PR] HDDS-11816. Ozone stream to support Hsync,Hflush. [ozone]
ashishkumar50 opened a new pull request, #7592:
URL: https://github.com/apache/ozone/pull/7592
## What changes were proposed in this pull request?
Support Ozone Streaming work with HSync and Hflush.
## What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-11816
## How was this patch tested?
New integration test and existing test
--
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: issues-unsubscribe@ozone.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org
Re: [PR] HDDS-11816. Ozone stream to support Hsync,Hflush. [ozone]
Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang merged PR #7592:
URL: https://github.com/apache/ozone/pull/7592
--
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: issues-unsubscribe@ozone.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org
Re: [PR] HDDS-11816. Ozone stream to support Hsync,Hflush. [ozone]
Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on code in PR #7592:
URL: https://github.com/apache/ozone/pull/7592#discussion_r1899830365
##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/fs/ozone/TestHSync.java:
##########
@@ -1061,6 +1064,31 @@ public void testStreamCapability() throws Exception {
testEncryptedStreamCapabilities(false);
}
+ @Test
+ public void testOzoneStreamCapabilityForHsyncHflush() throws Exception {
+ final String rootPath = String.format("%s://%s/",
+ OZONE_OFS_URI_SCHEME, CONF.get(OZONE_OM_ADDRESS_KEY));
+ CONF.set(CommonConfigurationKeysPublic.FS_DEFAULT_NAME_KEY, rootPath);
+ CONF.set(OZONE_FS_DATASTREAM_AUTO_THRESHOLD, AUTO_THRESHOLD + "B");
+ CONF.setBoolean(OZONE_FS_DATASTREAM_ENABLED, true);
+
+ final String dir = OZONE_ROOT + bucket.getVolumeName()
+ + OZONE_URI_DELIMITER + bucket.getName();
+ final Path file = new Path(dir, "file");
+
+ try (FileSystem fs = FileSystem.get(CONF);
+ FSDataOutputStream os = fs.create(file, true)) {
+ os.write(100);
+ // Verify output stream supports hsync() and hflush().
+ assertTrue(os.hasCapability(StreamCapabilities.HFLUSH),
+ "KeyOutputStream should support hflush()!");
+ assertTrue(os.hasCapability(StreamCapabilities.HSYNC),
+ "KeyOutputStream should support hsync()!");
+ }
Review Comment:
```suggestion
os.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: issues-unsubscribe@ozone.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org
Re: [PR] HDDS-11816. Ozone stream to support Hsync,Hflush. [ozone]
Posted by "jojochuang (via GitHub)" <gi...@apache.org>.
jojochuang commented on PR #7592:
URL: https://github.com/apache/ozone/pull/7592#issuecomment-2580909210
Thanks @ashishkumar50 !
--
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: issues-unsubscribe@ozone.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org