Repository: incubator-geode Updated Branches: refs/heads/develop 068d3bce1 -> 67053cacb
GEODE-952 removing heap-dumping code This code is no longer needed for GEODE-952 diagnosis. Project: http://git-wip-us.apache.org/repos/asf/incubator-geode/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-geode/commit/67053cac Tree: http://git-wip-us.apache.org/repos/asf/incubator-geode/tree/67053cac Diff: http://git-wip-us.apache.org/repos/asf/incubator-geode/diff/67053cac Branch: refs/heads/develop Commit: 67053cacb874879cb8ac8f3c64fe934156937005 Parents: 068d3bc Author: Bruce Schuchardt <[email protected]> Authored: Thu Mar 24 09:00:36 2016 -0700 Committer: Bruce Schuchardt <[email protected]> Committed: Thu Mar 24 09:02:31 2016 -0700 ---------------------------------------------------------------------- .../internal/InternalDistributedSystem.java | 29 ++------------------ 1 file changed, 3 insertions(+), 26 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-geode/blob/67053cac/geode-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java ---------------------------------------------------------------------- diff --git a/geode-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java b/geode-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java index 62755ca..b806b71 100644 --- a/geode-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java +++ b/geode-core/src/main/java/com/gemstone/gemfire/distributed/internal/InternalDistributedSystem.java @@ -941,37 +941,14 @@ public class InternalDistributedSystem */ public void disconnect(String reason, Throwable cause, boolean shunned) { boolean isForcedDisconnect = dm.getRootCause() instanceof ForcedDisconnectException; - boolean reconnected = false; + boolean rejoined = false; this.reconnected = false; if (isForcedDisconnect) { this.forcedDisconnect = true; resetReconnectAttemptCounter(); - if (sampler.isSamplingEnabled()) { - try { - // give the stat sampler time to take another sample - Thread.sleep(this.config.getStatisticSampleRate() * 2); - } catch (InterruptedException e) { - Thread.currentThread().interrupt(); - } - if (sampler.getStatSamplerStats().getJvmPauses() > 0) { - try { - // if running tests then create a heap dump - Class.forName("com.gemstone.gemfire.test.dunit.standalone.DUnitLauncher"); - Class<?> jmapClass = Class.forName("sun.tools.jmap.JMap"); - logger.info("This member of the distributed system has been forced to disconnect. JVM pauses have been detected - dumping heap"); - String pid = String.valueOf(OSProcess.getId()); - String fileName = "java"+pid+".hprof"; - Object parameters = new String[]{"-dump:format=b,file="+fileName, pid}; - Method main = jmapClass.getDeclaredMethod("main", String[].class); - main.invoke(null, parameters); - } catch (Exception e) { - } - } - } - - reconnected = tryReconnect(true, reason, GemFireCacheImpl.getInstance()); + rejoined = tryReconnect(true, reason, GemFireCacheImpl.getInstance()); } - if (!reconnected) { + if (!rejoined) { disconnect(false, reason, shunned); } }
