Search in sources :

Example 11 with TimelineEvent

use of org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent in project hadoop by apache.

the class TaskFinishedEvent method toTimelineEvent.

@Override
public TimelineEvent toTimelineEvent() {
    TimelineEvent tEvent = new TimelineEvent();
    tEvent.setId(StringUtils.toUpperCase(getEventType().name()));
    tEvent.addInfo("TASK_TYPE", getTaskType().toString());
    tEvent.addInfo("FINISH_TIME", getFinishTime());
    tEvent.addInfo("STATUS", TaskStatus.State.SUCCEEDED.toString());
    tEvent.addInfo("SUCCESSFUL_TASK_ATTEMPT_ID", getSuccessfulTaskAttemptId() == null ? "" : getSuccessfulTaskAttemptId().toString());
    return tEvent;
}
Also used : TimelineEvent(org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)

Example 12 with TimelineEvent

use of org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent in project hadoop by apache.

the class JobInitedEvent method toTimelineEvent.

@Override
public TimelineEvent toTimelineEvent() {
    TimelineEvent tEvent = new TimelineEvent();
    tEvent.setId(StringUtils.toUpperCase(getEventType().name()));
    tEvent.addInfo("START_TIME", getLaunchTime());
    tEvent.addInfo("STATUS", getStatus());
    tEvent.addInfo("TOTAL_MAPS", getTotalMaps());
    tEvent.addInfo("TOTAL_REDUCES", getTotalReduces());
    tEvent.addInfo("UBERIZED", getUberized());
    return tEvent;
}
Also used : TimelineEvent(org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)

Example 13 with TimelineEvent

use of org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent in project hadoop by apache.

the class JobPriorityChangeEvent method toTimelineEvent.

@Override
public TimelineEvent toTimelineEvent() {
    TimelineEvent tEvent = new TimelineEvent();
    tEvent.setId(StringUtils.toUpperCase(getEventType().name()));
    tEvent.addInfo("PRIORITY", getPriority().toString());
    return tEvent;
}
Also used : TimelineEvent(org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)

Example 14 with TimelineEvent

use of org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent in project hadoop by apache.

the class JobQueueChangeEvent method toTimelineEvent.

@Override
public TimelineEvent toTimelineEvent() {
    TimelineEvent tEvent = new TimelineEvent();
    tEvent.setId(StringUtils.toUpperCase(getEventType().name()));
    tEvent.addInfo("QUEUE_NAMES", getJobQueueName());
    return tEvent;
}
Also used : TimelineEvent(org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)

Example 15 with TimelineEvent

use of org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent in project hadoop by apache.

the class JobStatusChangedEvent method toTimelineEvent.

@Override
public TimelineEvent toTimelineEvent() {
    TimelineEvent tEvent = new TimelineEvent();
    tEvent.setId(StringUtils.toUpperCase(getEventType().name()));
    tEvent.addInfo("STATUS", getStatus());
    return tEvent;
}
Also used : TimelineEvent(org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)

Aggregations

TimelineEvent (org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent)56 TimelineEntity (org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntity)26 HashMap (java.util.HashMap)24 TimelineMetric (org.apache.hadoop.yarn.api.records.timelineservice.TimelineMetric)12 HashSet (java.util.HashSet)11 ApplicationEntity (org.apache.hadoop.yarn.api.records.timelineservice.ApplicationEntity)7 TimelineEntities (org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntities)7 Map (java.util.Map)5 Configuration (org.apache.hadoop.conf.Configuration)5 NavigableMap (java.util.NavigableMap)4 Set (java.util.Set)4 EventColumnName (org.apache.hadoop.yarn.server.timelineservice.storage.common.EventColumnName)4 ContainerId (org.apache.hadoop.yarn.api.records.ContainerId)3 TimelineDataToRetrieve (org.apache.hadoop.yarn.server.timelineservice.reader.TimelineDataToRetrieve)3 TimelineReaderContext (org.apache.hadoop.yarn.server.timelineservice.reader.TimelineReaderContext)3 EventColumnNameConverter (org.apache.hadoop.yarn.server.timelineservice.storage.common.EventColumnNameConverter)3 Test (org.junit.Test)3 BufferedReader (java.io.BufferedReader)2 FileReader (java.io.FileReader)2 IOException (java.io.IOException)2