@JsonSetter("createdtime") public void setCreatedTime(Long createdTs) { if (real == null) { this.createdTime = createdTs; } else { real.setCreatedTime(createdTs); } }
private TimelineEntity generateEntity(String entityType, String entityId) { TimelineEntity timelineEntity = new TimelineEntity(); timelineEntity.setId(entityId); timelineEntity.setType(entityType); timelineEntity.setCreatedTime(System.currentTimeMillis()); return timelineEntity; } }
private static TimelineEntity generateEntity(String id) { TimelineEntity entity = new TimelineEntity(); entity.setId(id); entity.setType("testEntity"); entity.setCreatedTime(System.currentTimeMillis()); return entity; }
private static TimelineEntity createEntity(String id, String type) { TimelineEntity entityToStore = new TimelineEntity(); entityToStore.setId(id); entityToStore.setType(type); entityToStore.setCreatedTime(0L); return entityToStore; }
long ts = System.currentTimeMillis(); if (appEvent == DSEvent.DS_APP_ATTEMPT_START) { entity.setCreatedTime(ts);
private org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntity createBaseEntity(HistoryEvent event, long timestamp, String entityType, boolean setCreatedTime) { org.apache.hadoop.yarn.api.records.timelineservice.TimelineEvent tEvent = event.toTimelineEvent(); tEvent.setTimestamp(timestamp); org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntity entity = new org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntity(); entity.addEvent(tEvent); entity.setType(entityType); if (setCreatedTime) { entity.setCreatedTime(timestamp); } Set<TimelineMetric> timelineMetrics = event.getTimelineMetrics(); if (timelineMetrics != null) { entity.setMetrics(timelineMetrics); } return entity; }
if (publishContainerEvents) { TimelineEntity entity = createContainerEntity(container.getContainerId()); entity.setCreatedTime(createdTime);
ApplicationAttemptId attemptId = appAttempt.getAppAttemptId(); TimelineEntity entity = createAppAttemptEntity(attemptId); entity.setCreatedTime(registeredTime);
entity.setId(container.getId().toString()); entity.setType(DSEntity.DS_CONTAINER.toString()); entity.setCreatedTime(startTime); entity.addInfo("user", appSubmitterUgi.getShortUserName());
entity.setId(id); entity.setType(type); entity.setCreatedTime(1425016501000L); te.addEntity(entity); entity2.setId(id2); entity2.setType(type2); entity2.setCreatedTime(1425016503000L); entity2.addMetric(metric); te.addEntity(entity2);
entity.setType(entityType); long cTime = 1425016501000L; entity.setCreatedTime(cTime);
entity.setCreatedTime(createdTime);
entity.setCreatedTime(createdTime);
entity.setCreatedTime(createdTime);
event1, event2); entity.setCreatedTime(0L); entity.addRelatesToEntity("test type 2", "test id 2"); entity.addRelatesToEntity("test type 3", "test id 3");
entity11.setId("id_1"); entity11.setType("app"); entity11.setCreatedTime(1425016502000L); Map<String, Object> info1 = new HashMap<String, Object>(); info1.put("info1", "val1"); entity2.setId("id_2"); entity2.setType("app"); entity2.setCreatedTime(1425016501050L); Map<String, Object> info2 = new HashMap<String, Object>(); info1.put("info2", 4); entity3.setId("id_3"); entity3.setType("app"); entity3.setCreatedTime(1425016501050L); Map<String, Object> info3 = new HashMap<String, Object>(); info3.put("info2", 3.5); entity4.setId("id_4"); entity4.setType("app"); entity4.setCreatedTime(1425016502050L); TimelineEvent event44 = new TimelineEvent(); event44.setId("event_4"); entity5.setId("id_5"); entity5.setType("app"); entity5.setCreatedTime(1425016502050L); writeEntityFile(entity5, appDir2);