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

HuangTao updated HDDS-3659:
---------------------------
    Description: 
Here is the reproduce process. Put three replication, then with one replication 
and/or  STAND_ALONE type , the replicationFactor of the output is 3 and type is 
still RATIS. Vice versa, put one replication first, the replicationFactor is 
always going to be 1.  
 # bin/ozone sh volume create myvol
 # bin/ozone sh bucket create /myvol/mybucket
 # bin/ozone sh key put -r THREE /myvol/mybucket/NOTICE.txt NOTICE.txt
 # bin/ozone sh key info /myvol/mybucket/NOTICE.txt
{code:json}
{
  "volumeName" : "myvol",
  "bucketName" : "mybucket",
  "name" : "NOTICE.txt",
  "dataSize" : 17540,
  "creationTime" : "2020-08-09T00:17:20.301Z",
  "modificationTime" : "2020-08-09T00:17:24.836Z",
  "replicationType" : "RATIS",
  "replicationFactor" : 3,
  "ozoneKeyLocations" : [ {
    "containerID" : 1,
    "localID" : 104656551297613824,
    "length" : 17540,
    "offset" : 0
  } ],
  "metadata" : { },
  "fileEncryptionInfo" : null
} {code}

 # bin/ozone sh key put -r ONE -t STAND_ALONE /myvol/mybucket/NOTICE.txt 
NOTICE.txt
 # bin/ozone sh key info /myvol/mybucket/NOTICE.txt 
{code:java}
 {
  "volumeName" : "myvol",
  "bucketName" : "mybucket",
  "name" : "NOTICE.txt",
  "dataSize" : 17540,
  "creationTime" : "2020-08-09T00:17:20.301Z",
  "modificationTime" : "2020-08-09T00:22:47.996Z",
  "replicationType" : "RATIS",
  "replicationFactor" : 3,
  "ozoneKeyLocations" : [ {
    "containerID" : 2,
    "localID" : 104656572569878529,
    "length" : 17540,
    "offset" : 0
  } ],
  "metadata" : { },
  "fileEncryptionInfo" : null
}{code}

  was:
Here is the reproduce process. Put three replication and then one replication, 
the replicationFactor of the output is 3. Vice versa, put one replication 
first, the replicationFactor is always going to be 1.  
 # bin/ozone sh volume create myvol
 # bin/ozone sh bucket create /myvol/mybucket
 # bin/ozone sh key put -r THREE /myvol/mybucket/NOTICE.txt NOTICE.txt
 # bin/ozone sh key info /myvol/mybucket/NOTICE.txt
{code:json}
{
  "volumeName" : "myvol",
  "bucketName" : "mybucket",
  "name" : "NOTICE.txt",
  "dataSize" : 17540,
  "creationTime" : "2020-08-09T00:17:20.301Z",
  "modificationTime" : "2020-08-09T00:17:24.836Z",
  "replicationType" : "RATIS",
  "replicationFactor" : 3,
  "ozoneKeyLocations" : [ {
    "containerID" : 1,
    "localID" : 104656551297613824,
    "length" : 17540,
    "offset" : 0
  } ],
  "metadata" : { },
  "fileEncryptionInfo" : null
} {code}

 # bin/ozone sh key put -r ONE /myvol/mybucket/NOTICE.txt NOTICE.txt
 # bin/ozone sh key info /myvol/mybucket/NOTICE.txt 
{code:java}
 {
  "volumeName" : "myvol",
  "bucketName" : "mybucket",
  "name" : "NOTICE.txt",
  "dataSize" : 17540,
  "creationTime" : "2020-08-09T00:17:20.301Z",
  "modificationTime" : "2020-08-09T00:22:47.996Z",
  "replicationType" : "RATIS",
  "replicationFactor" : 3,
  "ozoneKeyLocations" : [ {
    "containerID" : 2,
    "localID" : 104656572569878529,
    "length" : 17540,
    "offset" : 0
  } ],
  "metadata" : { },
  "fileEncryptionInfo" : null
}{code}


> put a new file to exist key with different factor or type don't update the 
> omkeyinfo
> ------------------------------------------------------------------------------------
>
>                 Key: HDDS-3659
>                 URL: https://issues.apache.org/jira/browse/HDDS-3659
>             Project: Hadoop Distributed Data Store
>          Issue Type: Bug
>          Components: Ozone Manager
>    Affects Versions: 0.6.0
>            Reporter: maobaolong
>            Assignee: HuangTao
>            Priority: Critical
>              Labels: Triaged
>
> Here is the reproduce process. Put three replication, then with one 
> replication and/or  STAND_ALONE type , the replicationFactor of the output is 
> 3 and type is still RATIS. Vice versa, put one replication first, the 
> replicationFactor is always going to be 1.  
>  # bin/ozone sh volume create myvol
>  # bin/ozone sh bucket create /myvol/mybucket
>  # bin/ozone sh key put -r THREE /myvol/mybucket/NOTICE.txt NOTICE.txt
>  # bin/ozone sh key info /myvol/mybucket/NOTICE.txt
> {code:json}
> {
>   "volumeName" : "myvol",
>   "bucketName" : "mybucket",
>   "name" : "NOTICE.txt",
>   "dataSize" : 17540,
>   "creationTime" : "2020-08-09T00:17:20.301Z",
>   "modificationTime" : "2020-08-09T00:17:24.836Z",
>   "replicationType" : "RATIS",
>   "replicationFactor" : 3,
>   "ozoneKeyLocations" : [ {
>     "containerID" : 1,
>     "localID" : 104656551297613824,
>     "length" : 17540,
>     "offset" : 0
>   } ],
>   "metadata" : { },
>   "fileEncryptionInfo" : null
> } {code}
>  # bin/ozone sh key put -r ONE -t STAND_ALONE /myvol/mybucket/NOTICE.txt 
> NOTICE.txt
>  # bin/ozone sh key info /myvol/mybucket/NOTICE.txt 
> {code:java}
>  {
>   "volumeName" : "myvol",
>   "bucketName" : "mybucket",
>   "name" : "NOTICE.txt",
>   "dataSize" : 17540,
>   "creationTime" : "2020-08-09T00:17:20.301Z",
>   "modificationTime" : "2020-08-09T00:22:47.996Z",
>   "replicationType" : "RATIS",
>   "replicationFactor" : 3,
>   "ozoneKeyLocations" : [ {
>     "containerID" : 2,
>     "localID" : 104656572569878529,
>     "length" : 17540,
>     "offset" : 0
>   } ],
>   "metadata" : { },
>   "fileEncryptionInfo" : null
> }{code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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

Reply via email to