Commit ef95e428 by huangfusuper

Plugin插件端数据库实现注册中心代码编写与修改

parent 192cfd39
...@@ -15,7 +15,12 @@ public class DataSourceServiceRegistry extends PluginServiceRegistry { ...@@ -15,7 +15,12 @@ public class DataSourceServiceRegistry extends PluginServiceRegistry {
private RegistryClient registryClient; private RegistryClient registryClient;
/**
* 做注册中心客户端对象的初始化
* @param biz 业务key
* @param env 环境标识
* @param registryUrl 注册中心的地址
*/
@Override @Override
public void init(String biz, String env, String registryUrl) { public void init(String biz, String env, String registryUrl) {
registryClient = new RegistryClient(registryUrl,null,biz,env); registryClient = new RegistryClient(registryUrl,null,biz,env);
...@@ -38,6 +43,16 @@ public class DataSourceServiceRegistry extends PluginServiceRegistry { ...@@ -38,6 +43,16 @@ public class DataSourceServiceRegistry extends PluginServiceRegistry {
return registryClient.registry(registryDataList); return registryClient.registry(registryDataList);
} }
/**
* 服务注册
* @param registryDataParamVOs 服务地址
* @return 注册层高
*/
@Override
public boolean registry(List<RegistryDataParamVO> registryDataParamVOs) {
return registryClient.registry(registryDataParamVOs);
}
@Override @Override
public boolean remove(List<RegistryDataParamVO> registryDataList) { public boolean remove(List<RegistryDataParamVO> registryDataList) {
if(registryClient != null){ if(registryClient != null){
......
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