You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Saketa Chalamchala (Jira)" <ji...@apache.org> on 2026/01/02 18:49:00 UTC

[jira] [Created] (HDDS-14337) SCM does not restart if it was first deployed near the end of year

Saketa Chalamchala created HDDS-14337:
-----------------------------------------

             Summary: SCM does not restart if it was first deployed near the end of year
                 Key: HDDS-14337
                 URL: https://issues.apache.org/jira/browse/HDDS-14337
             Project: Apache Ozone
          Issue Type: Bug
            Reporter: Saketa Chalamchala
            Assignee: Saketa Chalamchala


SCM fails to restart after it is first deployed and started near the end of the year, say on Dec 31, with the following error due to a Precondition fail that check if `localId > UniqueId.next()`

- `localId`: Uses millisSinceEpoch << Short.SIZE (shift by 16 bits)
- `UniqueId.next()`: Uses currentTimeMillis << 10 (shift by 10 bits)


Since UniqueId.next() shifts by fewer bits and includes the current time, while localId shifts by more bits but uses a future date (Jan 1st of next year), the values can be very close or even inverted, especially near year boundaries.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org