On Wed, 14 Jan 2026 21:12:30 GMT, Weijun Wang <[email protected]> wrote:
> Some comments. > > I have a small concern on the `Instant.now()` calls everywhere. As you can > see in your `TestKeyStoreBasic.java` test, the value is truncated when > persisting inside a keystore and when loaded again it's not identical to the > old value. Will this create any interop issue in the real world? If we know a > keystore implementation only support the precision of milliseconds, should we > truncate it early? I believe this would be the safest thing to do. Existing implementation is relying on `new Date()` which is actually calling `System.currentTimeMillis()` which is sufficient. Even though it shouldn't cause any interop issues as Date still remains unchanged `Instant` values can cause confusion as in the test. I have changed these 'Instant.now()' to `Instant.now().truncatedTo(ChronoUnit.MILLIS);` ------------- PR Comment: https://git.openjdk.org/jdk/pull/29140#issuecomment-3754263534
