errose28 commented on PR #6385: URL: https://github.com/apache/ozone/pull/6385#issuecomment-2013690253
> In Ozone, if you create a key, with objectID=5, and then create a new key of the same name, the objectID, I believe, remains the same, but the update_id is incremented. Object ID is derived from the Ratis transaction index of the create request. See [the method](https://github.com/apache/ozone/blob/4da5a642243a42bba1aea6701d3d6b4b3a9462b4/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java#L2147) doing the calculation that is called from all create requests. Note the extra space created around each object ID to account for directories that might need to be created with a file create request. **Creating a new key with the same name will have a different object ID.** Update ID is also set on key create but additionally changed when metadata like Native ACLs are changed. This is just the Ratis transaction index with no additional modifications. See [this method](https://github.com/apache/ozone/blob/b537a6a710e83a413cfba87c02e0357c0365d114/hadoop-ozone/common/src/main/java/org/apache/hadoop/ozone/om/helpers/WithObjectID.java#L69) and everywhere it is used for what operations modify the update ID. I'm not sure what you mean "update ID is incremented". The update ID of the new key will be arbitrarily larger than the old key since it is a Ratis transaction index, but its value is not related to the update ID of the previous version of the key. -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
