container/src/main/java/com/streamsets/datacollector/usagestats/ActiveStats.java
public ActiveStats snapshot() {
    ActiveStats snapshot = new ActiveStats().setStartTime(getStartTime())
                                            .setDataCollectorVersion(getDataCollectorVersion())
                                            .setDpmEnabled(isDpmEnabled())
                                            .setUpTime(getUpTime().snapshot())
                                            .setRecordCount(getRecordCount());
    snapshot.setPipelines(getPipelines().stream().map(UsageTimer::snapshot).collect(Collectors.toList()));
    snapshot.setStages(getStages().stream().map(UsageTimer::snapshot).collect(Collectors.toList()));
    return snapshot;
  }
public ActiveStats snapshot() {
    ActiveStats snapshot = new ActiveStats().setStartTime(getStartTime())
                                            .setDataCollectorVersion(getDataCollectorVersion())
                                            .setDpmEnabled(isDpmEnabled())
                                            .setUpTime(getUpTime().snapshot())
                                            .setRecordCount(getRecordCount());
    snapshot.setPipelines(getPipelines().stream().map(UsageTimer::snapshot).collect(Collectors.toList()));
    snapshot.setStages(getStages().stream().map(UsageTimer::snapshot).collect(Collectors.toList()));
    return snapshot;
  }
public ActiveStats snapshot ( ) { ActiveStats snapshot = new ActiveStats ( ) . setStartTime ( getStartTime ( ) ) . setDataCollectorVersion ( getDataCollectorVersion ( ) ) . setDpmEnabled ( isDpmEnabled ( ) ) . setUpTime ( getUpTime ( ) . snapshot ( ) ) . setRecordCount ( getRecordCount ( ) ) ; snapshot . setPipelines ( getPipelines ( ) . stream ( ) . map ( UsageTimer :: snapshot ) . collect ( Collectors . toList ( ) ) ) ; snapshot . setStages ( getStages ( ) . stream ( ) . map ( UsageTimer :: snapshot ) . collect ( Collectors . toList ( ) ) ) ; return snapshot ; }
returns a snapshot for persistency
returns a snapshot for persistency