You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by ct...@apache.org on 2022/04/29 00:56:58 UTC
[accumulo] 02/03: Use getCount for COUNT property types
This is an automated email from the ASF dual-hosted git repository.
ctubbsii pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/accumulo.git
commit 006ba33116e886982037babccdb95898149a6dd4
Author: Christopher Tubbs <ct...@apache.org>
AuthorDate: Thu Apr 28 20:56:03 2022 -0400
Use getCount for COUNT property types
---
.../java/org/apache/accumulo/server/replication/ReplicationUtil.java | 2 +-
.../org/apache/accumulo/manager/tableOps/bulkVer2/PrepBulkImport.java | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/server/base/src/main/java/org/apache/accumulo/server/replication/ReplicationUtil.java b/server/base/src/main/java/org/apache/accumulo/server/replication/ReplicationUtil.java
index c2cdab16a1..69c470dd3c 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/replication/ReplicationUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/replication/ReplicationUtil.java
@@ -69,7 +69,7 @@ public class ReplicationUtil {
// The number of threads each tserver will use at most to replicate data
int replicationThreadsPerServer =
- Integer.parseInt(context.getConfiguration().get(Property.REPLICATION_WORKER_THREADS));
+ context.getConfiguration().getCount(Property.REPLICATION_WORKER_THREADS);
// The total number of "slots" we have to replicate data
return activeTservers * replicationThreadsPerServer;
diff --git a/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/bulkVer2/PrepBulkImport.java b/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/bulkVer2/PrepBulkImport.java
index 6934573080..70cdca4018 100644
--- a/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/bulkVer2/PrepBulkImport.java
+++ b/server/manager/src/main/java/org/apache/accumulo/manager/tableOps/bulkVer2/PrepBulkImport.java
@@ -183,8 +183,8 @@ public class PrepBulkImport extends ManagerRepo {
VolumeManager fs = manager.getVolumeManager();
final Path bulkDir = new Path(bulkInfo.sourceDir);
- int maxTablets = Integer.parseInt(manager.getContext().getTableConfiguration(bulkInfo.tableId)
- .get(Property.TABLE_BULK_MAX_TABLETS));
+ int maxTablets = manager.getContext().getTableConfiguration(bulkInfo.tableId)
+ .getCount(Property.TABLE_BULK_MAX_TABLETS);
try (LoadMappingIterator lmi =
BulkSerialize.readLoadMapping(bulkDir.toString(), bulkInfo.tableId, fs::open)) {