Search in sources :

Example 1 with DummyStatisticsImpl

use of org.apache.geode.internal.statistics.DummyStatisticsImpl in project geode by apache.

the class InternalDistributedSystem method createAtomicStatistics.

public Statistics createAtomicStatistics(StatisticsType type, String textId, long numericId) {
    if (this.statsDisabled) {
        return new DummyStatisticsImpl(type, textId, numericId);
    }
    long myUniqueId = statsListUniqueId.getAndIncrement();
    Statistics result = StatisticsImpl.createAtomicNoOS(type, textId, numericId, myUniqueId, this);
    synchronized (statsList) {
        statsList.add(result);
        statsListModCount++;
    }
    return result;
}
Also used : Statistics(org.apache.geode.Statistics) LinuxProcFsStatistics(org.apache.geode.internal.statistics.platform.LinuxProcFsStatistics) DummyStatisticsImpl(org.apache.geode.internal.statistics.DummyStatisticsImpl)

Example 2 with DummyStatisticsImpl

use of org.apache.geode.internal.statistics.DummyStatisticsImpl in project geode by apache.

the class InternalDistributedSystem method createOsStatistics.

public Statistics createOsStatistics(StatisticsType type, String textId, long numericId, int osStatFlags) {
    if (this.statsDisabled) {
        return new DummyStatisticsImpl(type, textId, numericId);
    }
    long myUniqueId = statsListUniqueId.getAndIncrement();
    Statistics result = new LocalStatisticsImpl(type, textId, numericId, myUniqueId, false, osStatFlags, this);
    synchronized (statsList) {
        statsList.add(result);
        statsListModCount++;
    }
    return result;
}
Also used : LocalStatisticsImpl(org.apache.geode.internal.statistics.LocalStatisticsImpl) Statistics(org.apache.geode.Statistics) LinuxProcFsStatistics(org.apache.geode.internal.statistics.platform.LinuxProcFsStatistics) DummyStatisticsImpl(org.apache.geode.internal.statistics.DummyStatisticsImpl)

Aggregations

Statistics (org.apache.geode.Statistics)2 DummyStatisticsImpl (org.apache.geode.internal.statistics.DummyStatisticsImpl)2 LinuxProcFsStatistics (org.apache.geode.internal.statistics.platform.LinuxProcFsStatistics)2 LocalStatisticsImpl (org.apache.geode.internal.statistics.LocalStatisticsImpl)1