npawar commented on a change in pull request #5406:
URL: https://github.com/apache/incubator-pinot/pull/5406#discussion_r429500477



##########
File path: 
pinot-common/src/main/java/org/apache/pinot/common/function/DateTimeFunctions.java
##########
@@ -216,4 +217,18 @@ static String toDateTime(Long millis, String pattern) {
   static Long fromDateTime(String dateTimeString, String pattern) {
     return 
DateTimePatternHandler.parseDateTimeStringToEpochMillis(dateTimeString, 
pattern);
   }
+
+  /**
+   * Return current time as epoch millis
+   */
+  static Long now() {
+    return System.currentTimeMillis();
+  }
+
+  /**
+   * Return epoch millis value based on a given date time string and it's 
corresponding format.
+   */
+  public static Long formatDatetime(String input, String format) {

Review comment:
       this function is the same as `fromDateTime` on line 217. Do we need both?




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

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to