Commit 5f09c068 by 房斌

开会评审的

parent dc5ae692
...@@ -13,7 +13,7 @@ import org.slf4j.Logger; ...@@ -13,7 +13,7 @@ import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component; import org.springframework.stereotype.Component;
@Component
public class DubboUpdata implements UpDatas<ExecutorDetails> { public class DubboUpdata implements UpDatas<ExecutorDetails> {
private final Logger logger = LoggerFactory.getLogger(this.getClass()); private final Logger logger = LoggerFactory.getLogger(this.getClass());
String path; String path;
......
...@@ -88,7 +88,7 @@ public class DubboCustomerDownHock extends AbstractStop { ...@@ -88,7 +88,7 @@ public class DubboCustomerDownHock extends AbstractStop {
} }
//step3 check检查 //step3 check检查
if(checks!=null&&checks.size()>0) { if(checks!=null&&checks.size()>0) {
//等待 //TODO 监听hashmap的数据变化
CuratorZookeeperClient client = (CuratorZookeeperClient) getFieldValueByFieldName("zkClient", zookperRegster); CuratorZookeeperClient client = (CuratorZookeeperClient) getFieldValueByFieldName("zkClient", zookperRegster);
int sessionExpireMs = client.getUrl().getParameter("zk.session.expire", 10000); int sessionExpireMs = client.getUrl().getParameter("zk.session.expire", 10000);
Thread.sleep(sessionExpireMs);//zookper 目前最大超时时间 Thread.sleep(sessionExpireMs);//zookper 目前最大超时时间
......
...@@ -64,6 +64,7 @@ public class GracefullyShoutDown implements CommandLineRunner, ApplicationListen ...@@ -64,6 +64,7 @@ public class GracefullyShoutDown implements CommandLineRunner, ApplicationListen
@Override @Override
public void run(String... args) throws Exception { public void run(String... args) throws Exception {
if (DubboShutdownHook.getDubboShutdownHook() != null) { if (DubboShutdownHook.getDubboShutdownHook() != null) {
//TODO 判断是否dubbo组件,如果没有就不执行卸载和 shutDownhook
//hock卸载 //hock卸载
DubboShutdownHook.getDubboShutdownHook().unregister(); DubboShutdownHook.getDubboShutdownHook().unregister();
//listener 卸载 //listener 卸载
...@@ -172,6 +173,7 @@ public class GracefullyShoutDown implements CommandLineRunner, ApplicationListen ...@@ -172,6 +173,7 @@ public class GracefullyShoutDown implements CommandLineRunner, ApplicationListen
Iterator<StopService> it = ts.iterator(); Iterator<StopService> it = ts.iterator();
while (it.hasNext()) { while (it.hasNext()) {
StopService service = (StopService) it.next(); StopService service = (StopService) it.next();
//TODO tomcator 的connector是否加载
ExecutorDetail one = (ExecutorDetail) service.stop(); ExecutorDetail one = (ExecutorDetail) service.stop();
if (one != null) { if (one != null) {
details.add(one); details.add(one);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment