SOLR-8223: Avoid accidentally swallowing OutOfMemoryError (in LeaderInitiatedRecoveryThread.java or CoreContainer.java)

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1712817 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Christine Poerschke 2015-11-05 17:03:49 +00:00
parent 93974f9ddc
commit c2095b44fe
3 changed files with 6 additions and 3 deletions

View File

@ -330,6 +330,9 @@ Bug Fixes
* SOLR-7989: After a new leader is elected it should change it's state to ACTIVE even * SOLR-7989: After a new leader is elected it should change it's state to ACTIVE even
if the last published state is something else (Ishan Chattopadhyaya, Mark Miller via noble ) if the last published state is something else (Ishan Chattopadhyaya, Mark Miller via noble )
* SOLR-8223: Avoid accidentally swallowing OutOfMemoryError (in LeaderInitiatedRecoveryThread.java
or CoreContainer.java) (Mike Drob via Christine Poerschke)
Optimizations Optimizations
---------------------- ----------------------

View File

@ -211,7 +211,7 @@ public class LeaderInitiatedRecoveryThread extends Thread {
" command to core={} coreNodeName={} on " + recoveryUrl, coreNeedingRecovery, replicaCoreNodeName); " command to core={} coreNodeName={} on " + recoveryUrl, coreNeedingRecovery, replicaCoreNodeName);
continueTrying = false; // succeeded, so stop looping continueTrying = false; // succeeded, so stop looping
} catch (Throwable t) { } catch (Exception t) {
Throwable rootCause = SolrException.getRootCause(t); Throwable rootCause = SolrException.getRootCause(t);
boolean wasCommError = boolean wasCommError =
(rootCause instanceof ConnectException || (rootCause instanceof ConnectException ||

View File

@ -454,8 +454,8 @@ public class CoreContainer {
} }
try { try {
zkSys.registerInZk(core, true); zkSys.registerInZk(core, true);
} catch (Throwable t) { } catch (RuntimeException e) {
SolrException.log(log, "Error registering SolrCore", t); SolrException.log(log, "Error registering SolrCore", e);
} }
return core; return core;
} }