提交 e40bd46a 编写于 作者: W william.liangf

修改demo

git-svn-id: http://code.alibabatech.com/svn/dubbo/trunk@1711 1a56cb94-b969-4eaa-88fa-be21384802f2
上级 a2591496
......@@ -59,7 +59,7 @@ public class RouteAdd {
}
URL registryUrl = URL.valueOf(url).addParameter(Constants.CHECK_KEY, String.valueOf(false));
registry = registryFactory.getRegistry(registryUrl);
URL routeUrl = URL.valueOf("route://" + NetUtils.getLocalHost() + "/" + DemoService.class.getName() + "?category=routers&version=1.0.0&dynamic=false&priority=1&name=aaa&rule=" + URL.encode("consumer.host=" + NetUtils.getLocalHost() + " => provider.host=" + NetUtils.getLocalHost()));
URL routeUrl = URL.valueOf("condition://" + NetUtils.getLocalHost() + "/" + DemoService.class.getName() + "?category=routers&dynamic=false&rule=" + URL.encode("host=" + NetUtils.getLocalHost() + " => host=" + NetUtils.getLocalHost()));
registry.register(routeUrl);
}
......
......@@ -59,7 +59,7 @@ public class RouteRemove {
}
URL registryUrl = URL.valueOf(url).addParameter(Constants.CHECK_KEY, String.valueOf(false));
registry = registryFactory.getRegistry(registryUrl);
URL routeUrl = URL.valueOf("route://" + NetUtils.getLocalHost() + "/" + DemoService.class.getName() + "?category=routers&version=1.0.0&dynamic=false&priority=1&name=aaa&rule=" + URL.encode("consumer.host=" + NetUtils.getLocalHost() + " => provider.host=" + NetUtils.getLocalHost()));
URL routeUrl = URL.valueOf("condition://" + NetUtils.getLocalHost() + "/" + DemoService.class.getName() + "?category=routers&dynamic=false&rule=" + URL.encode("host=" + NetUtils.getLocalHost() + " => host=" + NetUtils.getLocalHost()));
registry.unregister(routeUrl);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册