mirror of https://github.com/apache/activemq.git
avoid any potential NPE and try again. git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@1304057 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
1463bec066
commit
d92d3a8a06
|
@ -145,6 +145,9 @@ public class FailoverTransport implements CompositeTransport {
|
||||||
if (priorityBackup && !connectedToPriority) {
|
if (priorityBackup && !connectedToPriority) {
|
||||||
try {
|
try {
|
||||||
doDelay();
|
doDelay();
|
||||||
|
if (reconnectTask == null) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
reconnectTask.wakeup();
|
reconnectTask.wakeup();
|
||||||
} catch (InterruptedException e) {
|
} catch (InterruptedException e) {
|
||||||
LOG.debug("Reconnect task has been interrupted.", e);
|
LOG.debug("Reconnect task has been interrupted.", e);
|
||||||
|
@ -154,6 +157,9 @@ public class FailoverTransport implements CompositeTransport {
|
||||||
// build backups on the next iteration
|
// build backups on the next iteration
|
||||||
buildBackup = true;
|
buildBackup = true;
|
||||||
try {
|
try {
|
||||||
|
if (reconnectTask == null) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
reconnectTask.wakeup();
|
reconnectTask.wakeup();
|
||||||
} catch (InterruptedException e) {
|
} catch (InterruptedException e) {
|
||||||
LOG.debug("Reconnect task has been interrupted.", e);
|
LOG.debug("Reconnect task has been interrupted.", e);
|
||||||
|
|
Loading…
Reference in New Issue