You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Duo Zhang (Jira)" <ji...@apache.org> on 2024/03/11 12:56:00 UTC

[jira] [Commented] (HBASE-28436) Use connection url to specify the connection registry information

    [ https://issues.apache.org/jira/browse/HBASE-28436?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17825292#comment-17825292 ] 

Duo Zhang commented on HBASE-28436:
-----------------------------------

I propose we just use the way described in the email to define the protocol.

hbase:zookeeper://host:port(,host:port)*/<zk_root_path>, is for zookeeper based connection registry
hbase:rpc://host:port(,host:port)*, is for rpc based connection registry

For MasterRegistry, I do not think we still need to support it here, as we will still support the old way to specify it.

As describe in the parent issue, we could use ServiceLoader to load different connection registry implementations. More specific, I think we could introduce a ConnectionRegistryFactory base interface(it is already there but since it is IA.Private, we could rename the old class...), which have two methods, one is the schema of this connection registry implementation, the other is a create method to create the actual ConnectionRegistry.

We will introduce a new configuration for specifying the connection url, if it is not present, we fallback to use the old way. And when creating ConnectionRegistry, we first check its scheme, and choose the correct ConnectionRegistryFactory to create the ConnectionRegistry. If there is no schema, we will fallback to use the old way.

Thanks.

> Use connection url to specify the connection registry information
> -----------------------------------------------------------------
>
>                 Key: HBASE-28436
>                 URL: https://issues.apache.org/jira/browse/HBASE-28436
>             Project: HBase
>          Issue Type: Sub-task
>          Components: Client
>            Reporter: Duo Zhang
>            Assignee: Duo Zhang
>            Priority: Major
>
> As describe in this email from [~ndimiduk]
> https://lists.apache.org/thread/98wqlkqvlnmpx3r7yrg9mw4pqz9ppofh
> The first advantage here is that, we can encode the connection registry implementation in the scheme of the connection url, so for replication, we can now support cluster key other than zookeeper, which is important for us to remove zookeeper dependency on our public facing APIs.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)