[
https://issues.apache.org/jira/browse/HDDS-6246?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17489274#comment-17489274
]
Jyotinder Singh commented on HDDS-6246:
---------------------------------------
Not able to reproduce this issue on latest master commit, looks like the case
is already handled in codebase.
{code:java}
bash-4.2$ ozone sh volume create /vol1
bash-4.2$ ozone sh bucket create /vol1/buck1
bash-4.2$ ozone sh bucket info /vol1/buck1
{
"volumeName" : "vol1",
"name" : "buck1",
...
"bucketLayout" : "OBJECT_STORE",
"link" : false
}
bash-4.2$ ozone sh key list /vol1/buck1
[ ]
bash-4.2$ ozone sh key put /vol1/buck1/a/b/c/d/key1 README.md
bash-4.2$ ozone sh key list /vol1/buck1 | grep "name"
"name" : "a/b/c/d/key1", {code}
Please feel free to open the Jira again if this issue comes back up.
> Ozone sh key list on OBJECT_STORE bucket
> ----------------------------------------
>
> Key: HDDS-6246
> URL: https://issues.apache.org/jira/browse/HDDS-6246
> Project: Apache Ozone
> Issue Type: Sub-task
> Reporter: Rakesh Radhakrishnan
> Assignee: Jyotinder Singh
> Priority: Major
>
> *Expected behavior :* Listing keys in OBS bucket shouldn't have the
> intermediate directories.
> But the below commands shows interm directories.
> "name" : "a/", "name" : "a/b/", "name" : "a/b/c/", "name" : "a/b/c/d/", Need
> to remove these items from the output.
> {code:java}
> [root@sample-1 ~]# ozone sh bucket info vol1/obsbuck1
> {
> "metadata" : { },
> "volumeName" : "vol1",
> "name" : "obsbuck1",
> "storageType" : "DISK",
> "versioning" : false,
> "usedBytes" : 69,
> "usedNamespace" : 1,
> "creationTime" : "2022-01-28T11:28:17.849Z",
> "modificationTime" : "2022-01-28T11:28:17.849Z",
> "quotaInBytes" : -1,
> "quotaInNamespace" : -1,
> "bucketLayout" : "OBJECT_STORE",
> "link" : false
> }
> [root@sample-1 ~]# ozone sh key list vol1/obsbuck1 | grep "name"
> "name" : "testroot/",
> [root@sample-1 ~]# ozone sh key put vol1/obsbuck1/a/b/c/d/test.txt
> /tmp/datafile
> [root@sample-1 ~]# ozone sh key list vol1/obsbuck1 | grep "name"
> "name" : "a/",
> "name" : "a/b/",
> "name" : "a/b/c/",
> "name" : "a/b/c/d/",
> "name" : "a/b/c/d/test.txt",
> "name" : "testroot/",
> {code}
--
This message was sent by Atlassian Jira
(v8.20.1#820001)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]