This is an automated email from the ASF dual-hosted git repository.

czy006 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/amoro.git


The following commit(s) were added to refs/heads/master by this push:
     new 5a02fa7ed [AMORO-3587] Modify the default value of hive catalog 
clients to 20 (#3590)
5a02fa7ed is described below

commit 5a02fa7ed044be197b86a6a3ad2c87e48a1edae4
Author: Darcy <[email protected]>
AuthorDate: Thu Jun 5 17:33:25 2025 +0800

    [AMORO-3587] Modify the default value of hive catalog clients to 20 (#3590)
    
    Modify the default value of hive catalog clients to 20
    
    Co-authored-by: Xu Bai <[email protected]>
---
 .../main/java/org/apache/amoro/server/catalog/CatalogBuilder.java    | 5 +++++
 .../main/java/org/apache/amoro/properties/CatalogMetaProperties.java | 2 +-
 docs/admin-guides/managing-catalogs.md                               | 1 +
 3 files changed, 7 insertions(+), 1 deletion(-)

diff --git 
a/amoro-ams/src/main/java/org/apache/amoro/server/catalog/CatalogBuilder.java 
b/amoro-ams/src/main/java/org/apache/amoro/server/catalog/CatalogBuilder.java
index 40d659ecf..c00310f35 100644
--- 
a/amoro-ams/src/main/java/org/apache/amoro/server/catalog/CatalogBuilder.java
+++ 
b/amoro-ams/src/main/java/org/apache/amoro/server/catalog/CatalogBuilder.java
@@ -23,6 +23,8 @@ import static 
org.apache.amoro.properties.CatalogMetaProperties.CATALOG_TYPE_CUS
 import static 
org.apache.amoro.properties.CatalogMetaProperties.CATALOG_TYPE_GLUE;
 import static 
org.apache.amoro.properties.CatalogMetaProperties.CATALOG_TYPE_HADOOP;
 import static 
org.apache.amoro.properties.CatalogMetaProperties.CATALOG_TYPE_HIVE;
+import static 
org.apache.amoro.properties.CatalogMetaProperties.CLIENT_POOL_SIZE;
+import static 
org.apache.amoro.properties.CatalogMetaProperties.CLIENT_POOL_SIZE_DEFAULT;
 
 import org.apache.amoro.TableFormat;
 import org.apache.amoro.api.CatalogMeta;
@@ -88,6 +90,9 @@ public class CatalogBuilder {
       case CATALOG_TYPE_HIVE:
         String amsUri = getAmsURI(serverConfiguration);
         catalogMeta.getCatalogProperties().put(CatalogMetaProperties.AMS_URI, 
amsUri);
+        catalogMeta
+            .getCatalogProperties()
+            .put(CLIENT_POOL_SIZE, String.valueOf(CLIENT_POOL_SIZE_DEFAULT));
         return new ExternalCatalog(catalogMeta);
       case CATALOG_TYPE_AMS:
         return new InternalCatalogImpl(catalogMeta, serverConfiguration);
diff --git 
a/amoro-common/src/main/java/org/apache/amoro/properties/CatalogMetaProperties.java
 
b/amoro-common/src/main/java/org/apache/amoro/properties/CatalogMetaProperties.java
index 59593aeed..906a3613b 100644
--- 
a/amoro-common/src/main/java/org/apache/amoro/properties/CatalogMetaProperties.java
+++ 
b/amoro-common/src/main/java/org/apache/amoro/properties/CatalogMetaProperties.java
@@ -64,7 +64,7 @@ public class CatalogMetaProperties {
   public static final String TABLE_FORMATS = "table-formats";
 
   public static final String CLIENT_POOL_SIZE = "clients";
-  public static final int CLIENT_POOL_SIZE_DEFAULT = 2;
+  public static final int CLIENT_POOL_SIZE_DEFAULT = 20;
 
   public static final String CLIENT_POOL_CACHE_EVICTION_INTERVAL_MS =
       "client.pool.cache.eviction-interval-ms";
diff --git a/docs/admin-guides/managing-catalogs.md 
b/docs/admin-guides/managing-catalogs.md
index 58a7a05bf..94e5eee55 100644
--- a/docs/admin-guides/managing-catalogs.md
+++ b/docs/admin-guides/managing-catalogs.md
@@ -69,6 +69,7 @@ You can create a catalog in the AMS frontend:
 Common properties include:
 - warehouse: Warehouse **must be configured** for ams/hadoop/glue catalog, as 
it determines where our database and table files should be placed
 - catalog-impl: when the metastore is **Custom**, an additional catalog-impl 
must be defined, and the user must put the jar package for the custom catalog 
implementation into the **{AMORO_HOME}/lib** directory, **and the service must 
be restarted to take effect**
+- clients: Hive Catalog connection pool size for accessing HiveMetaStore, 
default configuration is 20, requires restarting Amoro to take effect.
 - database-filter: Configure a regular expression to filter databases in the 
catalog. If not set then all databases will be displayed in table menu.
 - table-filter: Configure a regular expression to filter tables in the 
catalog. The matching will be done in the format of `database.table`. For 
example, if it is set to `(A\.a)|(B\.b)`, it will ignore all tables except for 
table `a` in database `A` and table `b` in database `B`
 

Reply via email to