gnodet-bot commented on code in PR #599:
URL: https://github.com/apache/maven-jar-plugin/pull/599#discussion_r4089118036


##########
src/main/java/org/apache/maven/plugins/jar/AbstractJarMojo.java:
##########
@@ -254,6 +268,14 @@ protected ToolProvider getJarTool() throws MojoException {
      * Returns the output timestamp or, as a fallback, the {@code 
SOURCE_DATE_EPOCH} environment variable.
      * If the timestamp is expressed in seconds, it is converted to ISO 8601 
format. Otherwise it is returned as-is.
      *
+     * <p>When the timestamp is given as a number of seconds and resolves to a 
date before {@code EPOCH_MIN}
+     * (1980-01-01T00:00:02Z — the minimum accepted by the {@code jar} tool 
due to the ZIP format constraint),

Review Comment:
   📝 **Javadoc inconsistency: "due to the ZIP format constraint" should be "due 
to a JDK sentinel constraint"**
   
   The `EPOCH_MIN` field Javadoc (lines 53–57 in the new file) now correctly 
states that `T00:00:02Z` is required because `1980-01-01T00:00:00Z` is a 
sentinel value (`DOSTIME_BEFORE_1980`) in the JDK ZIP implementation — not a 
ZIP format requirement. But this line still says "due to the ZIP format 
constraint", contradicting the field doc immediately above.
   
   Suggestion:
   ```suggestion
        * (1980-01-01T00:00:02Z — the minimum accepted by the {@code jar} tool 
due to the JDK sentinel constraint;
   ```



-- 
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]

Reply via email to