core/src/main/java/com/orientechnologies/orient/core/storage/impl/local/statistic/OSessionStoragePerformanceStatistic.java
public ODocument toDocument() {
    final ODocument document = performanceCountersHolder.toDocument();

    document.field("commitTime", getCommitTime(), OType.LONG);

    final Map<String, ODocument> countersMap = new HashMap<>();
    for (Map.Entry<String, PerformanceCountersHolder> entry : countersByComponent.entrySet()) {
      countersMap.put(entry.getKey(), entry.getValue().toDocument());
    }

    document.field("dataByComponent", countersMap, OType.EMBEDDEDMAP);

    if (walCountersHolder != null) {
      final ODocument wal = walCountersHolder.toDocument();
      document.field("walData", wal, OType.EMBEDDED);
    }

    return document;
  }
public ODocument toDocument() {
    final ODocument document = performanceCountersHolder.toDocument();

    document.field("commitTime", getCommitTime(), OType.LONG);

    final Map<String, ODocument> countersMap = new HashMap<>();
    for (Map.Entry<String, PerformanceCountersHolder> entry : countersByComponent.entrySet()) {
      countersMap.put(entry.getKey(), entry.getValue().toDocument());
    }

    document.field("dataByComponent", countersMap, OType.EMBEDDEDMAP);

    if (walCountersHolder != null) {
      final ODocument wal = walCountersHolder.toDocument();
      document.field("walData", wal, OType.EMBEDDED);
    }

    return document;
  }
Converts properties of given class into values of fields of returned document. Names of fields equal to names of properties.
<p>
All data related to separate components are stored in field <code>dataByComponent</code> map which has type
{@link OType#EMBEDDEDMAP} where key of map entry is name of component, and value is document which contains the same fields as
high level document but with values for single component not whole system.
<p>
Write ahead log performance data are stored inside of <code>walData</code> field.

@return Performance characteristics of storage gathered after call of
{@link OAbstractPaginatedStorage#startGatheringPerformanceStatisticForCurrentThread()}