felixYyu edited a comment on pull request #4444:
URL: https://github.com/apache/iceberg/pull/4444#issuecomment-1085257247
> What is the difference between Date.toString and Instant.toString?
@rdblue because Date has a bad API that leads to bugs, the static check
error log:
```
iceberg\core\src\main\java\org\apache\iceberg\RemoveSnapshots.java:121:
[JavaUtilDate] Date has a bad API that leads to bugs; prefer java.time.Instant
or LocalDate.
LOG.info("Expiring snapshots older than: {} ({})", new
Date(timestampMillis), timestampMillis);
^
(see https://errorprone.info/bugpattern/JavaUtilDate)
iceberg\core\src\main\java\org\apache\iceberg\ScanSummary.java:298:
[JavaUtilDate] Date has a bad API that leads to bugs; prefer java.time.Instant
or LocalDate.
new Date(dataTimestampMillis).toString() : null;
^
(see https://errorprone.info/bugpattern/JavaUtilDate)
```
--
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]