com.alibaba.dubbo.registry
Interface RegistryFactory

All Known Implementing Classes:
AbstractRegistryFactory, DubboRegistryFactory, MulticastRegistryFactory, RedisRegistryFactory, ZookeeperRegistryFactory

@SPI(value="dubbo")
public interface RegistryFactory

RegistryFactory. (SPI, Singleton, ThreadSafe)

Author:
william.liangf
See Also:
AbstractRegistryFactory

Method Summary
 Registry getRegistry(URL url)
          连接注册中心.
 

Method Detail

getRegistry

@Adaptive(value="protocol")
Registry getRegistry(URL url)
连接注册中心.

连接注册中心需处理契约:
1. 当设置check=false时表示不检查连接,否则在连接不上时抛出异常。
2. 支持URL上的username:password权限认证。
3. 支持backup=10.20.153.10备选注册中心集群地址。
4. 支持file=registry.cache本地磁盘文件缓存。
5. 支持timeout=1000请求超时设置。
6. 支持session=60000会话超时或过期设置。

Parameters:
url - 注册中心地址,不允许为空
Returns:
注册中心引用,总不返回空


Copyright © 2012–2017 Alibaba. All rights reserved.