/** * Creates a new <code>MemberHealthEvaluator</code> */ MemberHealthEvaluator(GemFireHealthConfig config, DM dm) { super(config, dm); this.config = config; InternalDistributedSystem system = dm.getSystem(); GemFireStatSampler sampler = system.getStatSampler(); if (sampler != null) { // Sampling is enabled // this.vmStats = sampler.getVMStats(); this.processStats = sampler.getProcessStats(); } this.dmStats = dm.getStats(); StringBuffer sb = new StringBuffer(); sb.append("Application VM member "); sb.append(dm.getId()); int pid = OSProcess.getId(); if (pid != 0) { sb.append(" with pid "); sb.append(pid); } this.description = sb.toString(); }
/** * Creates a new <code>MemberHealthEvaluator</code> */ MemberHealthEvaluator(GemFireHealthConfig config, DM dm) { super(config, dm); this.config = config; InternalDistributedSystem system = dm.getSystem(); GemFireStatSampler sampler = system.getStatSampler(); if (sampler != null) { // Sampling is enabled // this.vmStats = sampler.getVMStats(); this.processStats = sampler.getProcessStats(); } this.dmStats = dm.getStats(); StringBuffer sb = new StringBuffer(); sb.append("Application VM member "); sb.append(dm.getId()); int pid = OSProcess.getId(); if (pid != 0) { sb.append(" with pid "); sb.append(pid); } this.description = sb.toString(); }
public void addSystemStats() { GemFireStatSampler sampler = system.getStatSampler(); ProcessStats processStats = sampler.getProcessStats(); StatSamplerStats samplerStats = sampler.getStatSamplerStats(); if (processStats != null) { systemStatsMonitor.addStatisticsToMonitor(processStats.getStatistics()); } if(samplerStats != null){ systemStatsMonitor.addStatisticsToMonitor(samplerStats.getStats()); } }
public void addSystemStats() { GemFireStatSampler sampler = system.getStatSampler(); ProcessStats processStats = sampler.getProcessStats(); StatSamplerStats samplerStats = sampler.getStatSamplerStats(); if (processStats != null) { systemStatsMonitor.addStatisticsToMonitor(processStats.getStatistics()); } if(samplerStats != null){ systemStatsMonitor.addStatisticsToMonitor(samplerStats.getStats()); } }
ProcessStats stats = sampler.getProcessStats(); assertNotNull(stats);
assertNotNull(getProcessStats); ProcessStats processStats = statSampler.getProcessStats(); String osName = System.getProperty("os.name", "unknown"); if (osName.equals("SunOS")) {