[ https://issues.apache.org/jira/browse/YARN-3628?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14542988#comment-14542988 ]
zhihai xu commented on YARN-3628: --------------------------------- Sorry for the confusion. It is jmx. The following is empty container metrics shown from the jmx {code} { "name" : "Hadoop:service=NodeManager,name=ContainerResource_container_1431465632950_0001_01_000005", "modelerType" : "ContainerResource_container_1431465632950_0001_01_000005" } { "name" : "Hadoop:service=NodeManager,name=ContainerResource_container_1431465632950_0001_01_000002", "modelerType" : "ContainerResource_container_1431465632950_0001_01_000002" } {code} Normally the full container metrics will show like this: {code} { "name" : "Hadoop:service=NodeManager,name=ContainerResource_container_1431465632950_0001_01_000024", "modelerType" : "ContainerResource_container_1431465632950_0001_01_000024", "tag.ContainerResource" : "container_1431465632950_0001_01_000024", "tag.Context" : "container", "tag.ContainerPid" : "18748", "tag.Hostname" : "XXXXXXXX", "PMemUsageNumUsage" : 3, "PMemUsageAvgMBs" : 71.66666666666667, "PMemUsageStdevMBs" : 47.42713709821976, "PMemUsageIMinMBs" : 19.0, "PMemUsageIMaxMBs" : 111.0, "PMemUsageMinMBs" : 19.0, "PMemUsageMaxMBs" : 111.0, "pMemLimit" : 1024, "vMemLimit" : 2150, "vCoreLimit" : 1 } {code} > ContainerMetrics should support always-flush mode. > -------------------------------------------------- > > Key: YARN-3628 > URL: https://issues.apache.org/jira/browse/YARN-3628 > Project: Hadoop YARN > Issue Type: Improvement > Reporter: zhihai xu > Assignee: zhihai xu > Attachments: YARN-3628.000.patch > > > ContainerMetrics should support always-flush mode. > It will be good to set ContainerMetrics as always-flush mode if > yarn.nodemanager.container-metrics.period-ms is configured as 0. > Currently both 0 and -1 mean flush on completion. > Also the current default value for > yarn.nodemanager.container-metrics.period-ms is -1 and the default value for > yarn.nodemanager.container-metrics.enable is true. So the empty content is > shown for the active container metrics until it is finished. > The default value for yarn.nodemanager.container-metrics.period-ms should not > be -1. > flushOnPeriod is always false if flushPeriodMs is -1, > the content will only be shown when the container is finished. > {code} > if (finished || flushOnPeriod) { > registry.snapshot(collector.addRecord(registry.info()), all); > } > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)