You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by sh...@apache.org on 2023/05/25 09:47:53 UTC

[kafka] branch handleSnapshotLog created (now 3cd0c6fd560)

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

showuon pushed a change to branch handleSnapshotLog
in repository https://gitbox.apache.org/repos/asf/kafka.git


      at 3cd0c6fd560 use debug level to log handleCommit

This branch includes the following new commits:

     new 3cd0c6fd560 use debug level to log handleCommit

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[kafka] 01/01: use debug level to log handleCommit

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

showuon pushed a commit to branch handleSnapshotLog
in repository https://gitbox.apache.org/repos/asf/kafka.git

commit 3cd0c6fd56022fb6fc02e2f3cc3b0300eb7b4648
Author: Luke Chen <sh...@gmail.com>
AuthorDate: Thu May 25 17:47:11 2023 +0800

    use debug level to log handleCommit
---
 .../main/java/org/apache/kafka/image/loader/MetadataLoader.java   | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/metadata/src/main/java/org/apache/kafka/image/loader/MetadataLoader.java b/metadata/src/main/java/org/apache/kafka/image/loader/MetadataLoader.java
index 4b8d564971a..d8e96423022 100644
--- a/metadata/src/main/java/org/apache/kafka/image/loader/MetadataLoader.java
+++ b/metadata/src/main/java/org/apache/kafka/image/loader/MetadataLoader.java
@@ -315,9 +315,11 @@ public class MetadataLoader implements RaftClient.Listener<ApiMessageAndVersion>
                         setImage(image).
                         build();
                 LogDeltaManifest manifest = loadLogDelta(delta, reader);
-                log.info("handleSnapshot: generated a metadata delta from a snapshot at offset {} " +
-                        "in {} us.", manifest.provenance().lastContainedOffset(),
-                        NANOSECONDS.toMicros(manifest.elapsedNs()));
+                if (log.isDebugEnabled()) {
+                    log.debug("handleCommit: Generated a metadata delta between {} and {} from {} batch(es) " +
+                                    "in {} us.", image.offset(), manifest.provenance().lastContainedOffset(),
+                            manifest.numBatches(), NANOSECONDS.toMicros(manifest.elapsedNs()));
+                }
                 try {
                     image = delta.apply(manifest.provenance());
                 } catch (Throwable e) {