You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2022/05/09 13:06:29 UTC

[GitHub] [ozone] rakeshadr commented on a diff in pull request #3379: HDDS-6474. Fixed File System Optimized(FSO) bucket list status.

rakeshadr commented on code in PR #3379:
URL: https://github.com/apache/ozone/pull/3379#discussion_r867991202


##########
hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/fs/ozone/TestRootedOzoneFileSystemWithFSO.java:
##########
@@ -224,4 +225,19 @@ public void testDeleteVolumeAndBucket() throws IOException {
     Assert.assertTrue(deletes == prevDeletes + 1);
   }
 
+  @Test
+  public void testListStatusFSO() throws Exception {
+    Path parent = new Path(getBucketPath(), "testListStatusFSO");
+    for (int i = 0; i < 1300; i++) {
+      Path key = new Path(parent, "tempKey" + i);
+      ContractTestUtils.touch(getFs(), key);
+      // To add keys to the cache

Review Comment:
   @umamaheswararao @aswinshakil 
   >Only with rename, it keeping things in cache. It's good to know the differences
   
   Are you still seeing a table cache entry leaked in the latest code, with rename FSO operation ?
   
   _Details about the flushing and table cache cleanup logic:_ Hope this helps.
   
   step-1) Assume user performed `o3fs#rename(srcKey, dstKey)`;
   
   step-2) Then the call will reach OM server and will do rename metadata updation at OM : `OMKeyRenameRequest -> validateAndUpdateCache()`
   Here OM will update the keys and add these keys into TableCache.
   
   step-3) This is an async thread, which will do `OzoneManagerDoubleBuffer#flushTransactions()`
   Here it will add/update the DBTable and do TableCache cleanup by removing the flushed transaction Id.
   
   There are two reasons for seeing an item/key in TableCache:
   case-1) The entry is added to the TableCache and not yet flushed to DB. In reality the lifetime of a table cache entry is in between this petty small window.
   case-2) Bug situation: The cleanup of the tablecache is not done because of missing Table name in the response logic. This is a bug.
   For example, rename response class should have the DBTable names to be looked at and do the cleanup on flushing. If table name is not correctly mentioned, then that entry will not be removed and will exists in TableCache. This is a bug case.
   ```
   @CleanupTableInfo(cleanupTables = {FILE_TABLE, DIRECTORY_TABLE})
   public class OMKeyRenameResponseWithFSO extends OMKeyRenameResponse {
   ```



-- 
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