This commit is contained in:
mcy
2019-02-05 17:48:08 +08:00
parent 5284aa9793
commit f6d03bcb37
@@ -230,6 +230,9 @@ public class ESAdapter implements OuterAdapter {
@Override
public void destroy() {
if (esConfigMonitor != null) {
esConfigMonitor.destroy();
}
if (transportClient != null) {
transportClient.close();
}
@@ -237,10 +240,6 @@ public class ESAdapter implements OuterAdapter {
@Override
public String getDestination(String task) {
if (esConfigMonitor != null) {
esConfigMonitor.destroy();
}
ESSyncConfig config = esSyncConfig.get(task);
if (config != null) {
return config.getDestination();