From 57205bfc87b9aaf16b3442533bbd79b18af96840 Mon Sep 17 00:00:00 2001 From: Austin Heyne Date: Wed, 1 Nov 2023 10:53:24 -0400 Subject: [PATCH] GEOMESA-3310 HBase - Expose additional HBase configurations as system properties. Expose - geomesa.hbase.coprocessor.threads - geomesa.hbase.ranges.max-per-extended-scan - geomesa.hbase.ranges.max-per-coprocessor-scan Signed-off-by: Austin Heyne --- docs/user/hbase/configuration.rst | 15 +++++++++++++++ .../geomesa/hbase/data/HBaseDataStoreParams.scala | 5 ++++- .../org/locationtech/geomesa/hbase/package.scala | 3 +++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/docs/user/hbase/configuration.rst b/docs/user/hbase/configuration.rst index def2255c79fc..b9299153e22c 100644 --- a/docs/user/hbase/configuration.rst +++ b/docs/user/hbase/configuration.rst @@ -117,3 +117,18 @@ geomesa.hbase.query.block.caching.enabled Set whether blocks should be cached for scans, true by default. When true, default settings of the table and family are used (this will never override caching blocks if the block cache is disabled for that family or entirely). + +geomesa.hbase.coprocessor.threads ++++++++++++++++++++++++++++++++++ + +The number of HBase RPC threads to use per coprocessor query + +geomesa.hbase.ranges.max-per-extended-scan +++++++++++++++++++++++++++++++++++++++++++ + +Max ranges per extended scan. Ranges will be grouped into scans based on this setting. + +geomesa.hbase.ranges.max-per-coprocessor-scan ++++++++++++++++++++++++++++++++++++++++++++++ + +Max ranges per coprocessor scan. Ranges will be grouped into scans based on this setting diff --git a/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/data/HBaseDataStoreParams.scala b/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/data/HBaseDataStoreParams.scala index dbaa8468f9bf..495856ee52d9 100644 --- a/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/data/HBaseDataStoreParams.scala +++ b/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/data/HBaseDataStoreParams.scala @@ -14,7 +14,7 @@ import org.locationtech.geomesa.hbase.HBaseSystemProperties import org.locationtech.geomesa.index.geotools.GeoMesaDataStoreFactory.GeoMesaDataStoreParams import org.locationtech.geomesa.security.SecurityParams import org.locationtech.geomesa.utils.geotools.GeoMesaParam -import org.locationtech.geomesa.utils.geotools.GeoMesaParam.{ReadWriteFlag, SystemPropertyBooleanParam} +import org.locationtech.geomesa.utils.geotools.GeoMesaParam.{ReadWriteFlag, SystemPropertyBooleanParam, SystemPropertyIntegerParam} object HBaseDataStoreParams extends GeoMesaDataStoreParams with SecurityParams { @@ -57,6 +57,7 @@ object HBaseDataStoreParams extends GeoMesaDataStoreParams with SecurityParams { "The number of HBase RPC threads to use per coprocessor query", default = Int.box(16), supportsNiFiExpressions = true, + systemProperty = Some(SystemPropertyIntegerParam(HBaseSystemProperties.CoprocessorThreadsProperty)), readWrite = ReadWriteFlag.ReadOnly ) @@ -84,6 +85,7 @@ object HBaseDataStoreParams extends GeoMesaDataStoreParams with SecurityParams { default = 100, deprecatedKeys = Seq("max.ranges.per.extended.scan"), supportsNiFiExpressions = true, + systemProperty = Some(SystemPropertyIntegerParam(HBaseSystemProperties.MaxRangesPerExtendedScanProperty)), readWrite = ReadWriteFlag.ReadUpdate ) @@ -93,6 +95,7 @@ object HBaseDataStoreParams extends GeoMesaDataStoreParams with SecurityParams { "Max ranges per coprocessor scan. Ranges will be grouped into scans based on this setting", default = Int.MaxValue, supportsNiFiExpressions = true, + systemProperty = Some(SystemPropertyIntegerParam(HBaseSystemProperties.MaxRangesPerCoprocessorScanProperty)), readWrite = ReadWriteFlag.ReadOnly ) diff --git a/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/package.scala b/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/package.scala index d8f63017afba..f63ade384e09 100644 --- a/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/package.scala +++ b/geomesa-hbase/geomesa-hbase-datastore/src/main/scala/org/locationtech/geomesa/hbase/package.scala @@ -30,6 +30,9 @@ package object hbase { val RemoteDensityProperty : SystemProperty = SystemProperty("geomesa.hbase.coprocessor.density.enable") val RemoteStatsProperty : SystemProperty = SystemProperty("geomesa.hbase.coprocessor.stats.enable") val YieldPartialResultsProperty: SystemProperty = SystemProperty("geomesa.hbase.coprocessor.yield.partial.results") + val CoprocessorThreadsProperty : SystemProperty = SystemProperty("geomesa.hbase.coprocessor.threads", "16") + val MaxRangesPerExtendedScanProperty : SystemProperty = SystemProperty("geomesa.hbase.ranges.max-per-extended-scan", "100") + val MaxRangesPerCoprocessorScanProperty: SystemProperty = SystemProperty("geomesa.hbase.ranges.max-per-coprocessor-scan", Int.MaxValue.toString) @deprecated("Use coprocessor url") val CoprocessorPath: SystemProperty = SystemProperty("geomesa.hbase.coprocessor.path")