wirybeaver opened a new issue, #11491:
URL: https://github.com/apache/pinot/issues/11491
````
/**
* Returns the age of the file
* @param uri location of file or directory
* @return A long value representing the time the file was last modified,
measured in milliseconds since epoch
* (00:00:00 GMT, January 1, 1970) or 0L if the file does not exist or if
an I/O error occurs
* @throws IOException if uri is not valid or not present
*/
long lastModified(URI uri)
throws IOException;
```
Return 0L is very error prone since user might forgot to check the result.
The narrative "return 0L if the file does not exist or if an I/O error occurs"
and "throws IOException if uri is not valid or not present" are irreconcilable
paradoxes.
Given that some teams might already implement this interface with 0L check.
Can we deprecate lastModified(URI uir) and create a new method, e.g.,
`modifyTime(URI uri)`
--
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]