ableegoldman commented on a change in pull request #10926:
URL: https://github.com/apache/kafka/pull/10926#discussion_r659377314



##########
File path: 
streams/src/main/java/org/apache/kafka/streams/kstream/TimeWindows.java
##########
@@ -83,16 +92,52 @@ private TimeWindows(final long sizeMs, final long 
advanceMs, final long graceMs)
      * Tumbling windows are a special case of hopping windows with {@code 
advance == size}.
      *
      * @param size The size of the window
-     * @return a new window definition with default maintain duration of 1 day
+     * @return a new window definition with default no grace period
+     * @throws IllegalArgumentException if the specified window size is zero 
or negative or can't be represented as {@code long milliseconds}
+     */
+    public static TimeWindows ofSizeWithNoGrace(final Duration size) throws 
IllegalArgumentException {

Review comment:
       Call it out explicitly in the javadocs, I mean. ie in the description 
part, not just the `@return` (though it's good to have put it there too). It 
would be a good idea to describe what the grace period actually means in the 
javadocs of this method like we do in `ofSizeAndGrace` so that users know what 
it is they are losing by opting out of the grace period.




-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to