Search in sources :

Example 1 with TimelineServiceV1Publisher

use of org.apache.hadoop.yarn.server.resourcemanager.metrics.TimelineServiceV1Publisher in project hadoop by apache.

the class ResourceManager method createSystemMetricsPublisher.

protected SystemMetricsPublisher createSystemMetricsPublisher() {
    SystemMetricsPublisher publisher;
    if (YarnConfiguration.timelineServiceEnabled(conf) && YarnConfiguration.systemMetricsPublisherEnabled(conf)) {
        if (YarnConfiguration.timelineServiceV2Enabled(conf)) {
            // we're dealing with the v.2.x publisher
            LOG.info("system metrics publisher with the timeline service V2 is " + "configured");
            publisher = new TimelineServiceV2Publisher(rmContext);
        } else {
            // we're dealing with the v.1.x publisher
            LOG.info("system metrics publisher with the timeline service V1 is " + "configured");
            publisher = new TimelineServiceV1Publisher();
        }
    } else {
        LOG.info("TimelineServicePublisher is not configured");
        publisher = new NoOpSystemMetricPublisher();
    }
    return publisher;
}
Also used : SystemMetricsPublisher(org.apache.hadoop.yarn.server.resourcemanager.metrics.SystemMetricsPublisher) TimelineServiceV2Publisher(org.apache.hadoop.yarn.server.resourcemanager.metrics.TimelineServiceV2Publisher) TimelineServiceV1Publisher(org.apache.hadoop.yarn.server.resourcemanager.metrics.TimelineServiceV1Publisher) NoOpSystemMetricPublisher(org.apache.hadoop.yarn.server.resourcemanager.metrics.NoOpSystemMetricPublisher)

Aggregations

NoOpSystemMetricPublisher (org.apache.hadoop.yarn.server.resourcemanager.metrics.NoOpSystemMetricPublisher)1 SystemMetricsPublisher (org.apache.hadoop.yarn.server.resourcemanager.metrics.SystemMetricsPublisher)1 TimelineServiceV1Publisher (org.apache.hadoop.yarn.server.resourcemanager.metrics.TimelineServiceV1Publisher)1 TimelineServiceV2Publisher (org.apache.hadoop.yarn.server.resourcemanager.metrics.TimelineServiceV2Publisher)1