提交 9ad9ad06 编写于 作者: Y yukon

[ROCKETMQ-238] Catch Throwable to avoid error cancel some key scheduled tasks.

上级 b70b6800
......@@ -296,7 +296,7 @@ public class BrokerController {
public void run() {
try {
BrokerController.this.protectBroker();
} catch (Exception e) {
} catch (Throwable e) {
log.error("protectBroker error.", e);
}
}
......@@ -307,7 +307,7 @@ public class BrokerController {
public void run() {
try {
BrokerController.this.printWaterMark();
} catch (Exception e) {
} catch (Throwable e) {
log.error("printWaterMark error.", e);
}
}
......
......@@ -45,8 +45,8 @@ public class ClientHousekeepingService implements ChannelEventListener {
public void run() {
try {
ClientHousekeepingService.this.scanExceptionChannel();
} catch (Exception e) {
log.error("", e);
} catch (Throwable e) {
log.error("Error occurred when scan not active client channels.", e);
}
}
}, 1000 * 10, 1000 * 10, TimeUnit.MILLISECONDS);
......
......@@ -166,7 +166,7 @@ public class NettyRemotingClient extends NettyRemotingAbstract implements Remoti
public void run() {
try {
NettyRemotingClient.this.scanResponseTable();
} catch (Exception e) {
} catch (Throwable e) {
log.error("scanResponseTable exception", e);
}
}
......
......@@ -195,7 +195,7 @@ public class NettyRemotingServer extends NettyRemotingAbstract implements Remoti
public void run() {
try {
NettyRemotingServer.this.scanResponseTable();
} catch (Exception e) {
} catch (Throwable e) {
log.error("scanResponseTable exception", e);
}
}
......
......@@ -1443,7 +1443,7 @@ public class DefaultMessageStore implements MessageStore {
this.deleteExpiredFiles();
this.redeleteHangedFile();
} catch (Exception e) {
} catch (Throwable e) {
DefaultMessageStore.log.warn(this.getServiceName() + " service has exception. ", e);
}
}
......@@ -1583,7 +1583,7 @@ public class DefaultMessageStore implements MessageStore {
public void run() {
try {
this.deleteExpiredFiles();
} catch (Exception e) {
} catch (Throwable e) {
DefaultMessageStore.log.warn(this.getServiceName() + " service has exception. ", e);
}
}
......
......@@ -121,7 +121,7 @@ public class ScheduleMessageService extends ConfigManager {
public void run() {
try {
ScheduleMessageService.this.persist();
} catch (Exception e) {
} catch (Throwable e) {
log.error("scheduleAtFixedRate flush exception", e);
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册