[ 
https://issues.apache.org/jira/browse/HDDS-17413?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Gargi Jaiswal reassigned HDDS-17413:
------------------------------------

    Assignee: Aayush Gupta

> FSO key listing skips other matching directories when the prefix is an 
> existing directory
> -----------------------------------------------------------------------------------------
>
>                 Key: HDDS-17413
>                 URL: https://issues.apache.org/jira/browse/HDDS-17413
>             Project: Apache Ozone
>          Issue Type: Bug
>          Components: Ozone Manager, S3
>            Reporter: Huang Kuan Hao
>            Assignee: Aayush Gupta
>            Priority: Major
>
> In an FSO bucket, a non-shallow key listing whose prefix is also an existing 
> directory returns only that directory, and misses other directories that 
> match the prefix.
> Reproduced on master at 1f9f4cc791.
> h3. Reproduction
> Create keys {{dir1bh/file1}} and {{dir1bha/file1}}, then list keys with 
> prefix {{dir1bh}}:
> {noformat}
> OzoneBucket#listKeys("dir1bh", "", false)
>   LEGACY: dir1bh/, dir1bh/file1, dir1bha/, dir1bha/file1
>   FSO:    dir1bh/, dir1bh/file1
> {noformat}
> S3 ListObjects and ListObjectsV2 without a delimiter use this listing, so on 
> an FSO bucket {{list-objects-v2 --prefix dir1bh}} misses {{dir1bha/file1}}. 
> Shallow listing ({{delimiter=/}}) returns {{dir1bh/}} and {{dir1bha/}} for 
> both layouts.
> h3. Cause
> KeyIteratorWithFSO#getChildrenKeys calls listStatusLight with the prefix as 
> keyName and allowPartialPrefixes=true. When the keyName resolves to a 
> directory, OzoneListStatusHelper#listStatusFSO lists only that directory's 
> children. The partial-prefix handling from HDDS-9065 covers only missing keys 
> and files, so {{dir1bha/}} is never visited.
> h3. Context
> * Found while reviewing [HDDS-17308 / PR 
> #11715|https://github.com/apache/ozone/pull/11715]. Its FSO tests compare 
> against the listing without StartAfter because of this.
> * Not related to StartAfter.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to