[
https://issues.apache.org/jira/browse/DRILL-5230?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15850828#comment-15850828
]
ASF GitHub Bot commented on DRILL-5230:
---------------------------------------
GitHub user kkhatua opened a pull request:
https://github.com/apache/drill/pull/739
DRILL-5230: Translation of millisecond duration into hours is incorrect
Fixed invalid representation of readable elapsed time using `TimeUnit`
class in JDK.
e.g. 4545 sec is now correctly translated as `1h15m` instead of `17h15m`
TestCase has been added
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/kkhatua/drill DRILL-5230
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/drill/pull/739.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #739
----
commit bc9ed385d991ac3b6bab5a1ee9a10c649af5be6a
Author: Kunal Khatua <[email protected]>
Date: 2017-01-30T07:08:12Z
DRILL-5230: Translation of millisecond duration into hours is incorrect
Fixed invalid representation of readable elapsed time using `TimeUnit`
class in JDK.
e.g. 4545 sec is now correctly translated as `1h15m` instead of `17h15m`
----
> Translation of millisecond duration into hours is incorrect
> -----------------------------------------------------------
>
> Key: DRILL-5230
> URL: https://issues.apache.org/jira/browse/DRILL-5230
> Project: Apache Drill
> Issue Type: Bug
> Components: Web Server
> Affects Versions: 1.9.0
> Reporter: Kunal Khatua
> Labels: easyfix
> Fix For: 1.10.0
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> The method
> {code:JAVA}org.apache.drill.exec.server.rest.profile.TableBuilder.appendMillis(long,
> String){code}
> has a bug where the human readable translation of a 1+ hr duration in
> milliseconds is reported incorrectly.
> This has to do with the {code:JAVA}SimpleDateFormat.format() {code} method
> incorectly translating it.
> For e.g.
> {code:JAVA}
> long x = 4545342L; //1 hour 15 min 45.342 sec
> public void appendMillis(x, null);
> {code}
> This formats the value as {noformat}17h15m{noformat} instead of
> {noformat}1h15m{noformat}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)