This is an automated email from the ASF dual-hosted git repository.
hemant pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git
The following commit(s) were added to refs/heads/master by this push:
new 59573e4b12 HDDS-9722. Add some logging when KeyDeletingService is
running (#5626)
59573e4b12 is described below
commit 59573e4b123c9ddad1764fb36988749ebf1f7280
Author: jianghuazhu <[email protected]>
AuthorDate: Mon Nov 20 13:34:15 2023 -0600
HDDS-9722. Add some logging when KeyDeletingService is running (#5626)
---
.../hadoop/ozone/om/service/AbstractKeyDeletingService.java | 11 +++++++++++
.../apache/hadoop/ozone/om/service/KeyDeletingService.java | 3 ++-
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git
a/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/AbstractKeyDeletingService.java
b/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/AbstractKeyDeletingService.java
index 2becd9b026..6c8a111f1d 100644
---
a/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/AbstractKeyDeletingService.java
+++
b/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/AbstractKeyDeletingService.java
@@ -103,6 +103,17 @@ public abstract class AbstractKeyDeletingService extends
BackgroundService
long startTime = Time.monotonicNow();
int delCount = 0;
+ if (LOG.isDebugEnabled()) {
+ LOG.debug("Send {} key(s) to SCM: {}",
+ keyBlocksList.size(), keyBlocksList);
+ } else if (LOG.isInfoEnabled()) {
+ int logSize = 10;
+ if (keyBlocksList.size() < logSize) {
+ logSize = keyBlocksList.size();
+ }
+ LOG.info("Send {} key(s) to SCM, first {} keys: {}",
+ keyBlocksList.size(), logSize, keyBlocksList.subList(0, logSize));
+ }
List<DeleteBlockGroupResult> blockDeletionResults =
scmClient.deleteKeyBlocks(keyBlocksList);
if (blockDeletionResults != null) {
diff --git
a/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/KeyDeletingService.java
b/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/KeyDeletingService.java
index a0ca1ae547..6dcc2544b4 100644
---
a/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/KeyDeletingService.java
+++
b/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/KeyDeletingService.java
@@ -186,7 +186,8 @@ public class KeyDeletingService extends
AbstractKeyDeletingService {
// Check if this is the Leader OM. If not leader, no need to execute this
// task.
if (shouldRun()) {
- getRunCount().incrementAndGet();
+ final long run = getRunCount().incrementAndGet();
+ LOG.debug("Running KeyDeletingService {}", run);
// Acquire active DB deletedTable write lock because of the
// deletedTable read-write here to avoid interleaving with
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]