[jboss-jira] [JBoss JIRA] (WFLY-11394) Wrong units of jvm.uptime metric - milliseconds vs. seconds

Rostislav Svoboda (Jira) issues at jboss.org
Wed Nov 21 10:11:00 EST 2018


    [ https://issues.jboss.org/browse/WFLY-11394?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13664685#comment-13664685 ] 

Rostislav Svoboda commented on WFLY-11394:
------------------------------------------

When I ask for JSON I get milliseconds, this is weird.

{code}
curl http://localhost:9990/metrics/base/jvm.uptime -H "Accept: application/json" && echo " vs." && curl http://localhost:9990/metrics/base/jvm.uptime
{  "jvm.uptime" : 2504965}
 vs.
# HELP base:jvm_uptime_seconds Displays the start time of the Java virtual machine in milliseconds. This attribute displays the approximate time when the Java virtual machine started.
# TYPE base:jvm_uptime_seconds gauge
base:jvm_uptime_seconds 2504.986
{code}

> Wrong units of jvm.uptime metric - milliseconds vs. seconds
> -----------------------------------------------------------
>
>                 Key: WFLY-11394
>                 URL: https://issues.jboss.org/browse/WFLY-11394
>             Project: WildFly
>          Issue Type: Bug
>          Components: MP Metrics
>            Reporter: Rostislav Svoboda
>            Assignee: Jeff Mesnil
>            Priority: Major
>
> Wrong units of jvm.uptime metric - milliseconds vs. seconds
> {code}
> curl -H "Accept: application/json" -X OPTIONS http://localhost:9990/metrics/base/jvm.uptime
> {
>     "jvm.uptime": {
>         "unit": "milliseconds",
>         "type": "gauge",
>         "description": "Displays the start time of the Java virtual machine in milliseconds. This attribute displays the approximate time when the Java virtual machine started.",
>         "displayName": "JVM Uptime",
>         "tags": ""
>     }
> {code}
> This metric reports results in seconds, not in milliseconds as description says.
> {code}
> curl http://localhost:9990/metrics/base/jvm.uptime
> # HELP base:jvm_uptime_seconds Displays the start time of the Java virtual machine in milliseconds. This attribute displays the approximate time when the Java virtual machine started.
> # TYPE base:jvm_uptime_seconds gauge
> base:jvm_uptime_seconds 2011.875
> {code}



--
This message was sent by Atlassian Jira
(v7.12.1#712002)


More information about the jboss-jira mailing list