类 ServiceURI
java.lang.Object
org.apache.pulsar.common.net.ServiceURI
ServiceURI represents service uri within pulsar cluster.
This file is based on {@link https://github.com/apache/bookkeeper/blob/master/bookkeeper-common/src/main/java/org/apache/bookkeeper/common/net/ServiceURI.java}
-
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static ServiceURICreate a service uri instance from a uri string.static ServiceURICreate a service uri instance from aURIinstance.String[]String[]Create a new URI from the service URI which only specifies one of the hosts.
-
构造器详细资料
-
ServiceURI
public ServiceURI()
-
-
方法详细资料
-
create
Create a service uri instance from a uri string.- 参数:
uriStr- service uri string- 返回:
- a service uri instance
- 抛出:
NullPointerExceptionFieldParser- ifuriStris nullIllegalArgumentException- if the given string violates RFC 2396
-
create
Create a service uri instance from aURIinstance.- 参数:
uri-URIinstance- 返回:
- a service uri instance
- 抛出:
NullPointerException- ifuriStris nullIllegalArgumentException- if the given string violates RFC 2396
-
getServiceInfos
-
getServiceHosts
-
getServiceScheme
-
selectOne
Create a new URI from the service URI which only specifies one of the hosts.- 返回:
- a pulsar service URI with a single host specified
-