You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "ASF GitHub Bot (Jira)" <ji...@apache.org> on 2020/07/29 17:41:00 UTC

[jira] [Work logged] (HIVE-21611) Date.getTime() can be changed to System.currentTimeMillis()

     [ https://issues.apache.org/jira/browse/HIVE-21611?focusedWorklogId=464143&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-464143 ]

ASF GitHub Bot logged work on HIVE-21611:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 29/Jul/20 17:40
            Start Date: 29/Jul/20 17:40
    Worklog Time Spent: 10m 
      Work Description: HunterL edited a comment on pull request #595:
URL: https://github.com/apache/hive/pull/595#issuecomment-665744568


   > Please remove usage of Date entirely from these classes.
   @belugabehr 
   
   #1334 rebased and changed other uses


----------------------------------------------------------------
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:
users@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 464143)
    Time Spent: 0.5h  (was: 20m)

> Date.getTime() can be changed to System.currentTimeMillis()
> -----------------------------------------------------------
>
>                 Key: HIVE-21611
>                 URL: https://issues.apache.org/jira/browse/HIVE-21611
>             Project: Hive
>          Issue Type: Bug
>            Reporter: bd2019us
>            Assignee: Hunter Logan
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: 1.patch
>
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Hello,
> I found that System.currentTimeMillis() can be used here instead of new Date.getTime().
> Since new Date() is a thin wrapper of light method System.currentTimeMillis(). The performance will be greatly damaged if it is invoked too much times.
> According to my local testing at the same environment, System.currentTimeMillis() can achieve a speedup to 5 times (435 ms vs 2073 ms), when these two methods are invoked 5,000,000 times.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)