You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by GitBox <gi...@apache.org> on 2022/05/26 14:19:55 UTC

[GitHub] [ignite] xtern commented on a diff in pull request #10036: IGNITE-17005 Implement metrics for a snapshot create operation

xtern commented on code in PR #10036:
URL: https://github.com/apache/ignite/pull/10036#discussion_r882721198


##########
modules/core/src/main/java/org/apache/ignite/internal/processors/cache/persistence/snapshot/IgniteSnapshotManager.java:
##########
@@ -509,6 +509,24 @@ public static String partDeltaFileName(int partId) {
             "The list of names of all snapshots currently saved on the local node with respect to " +
                 "the configured via IgniteConfiguration snapshot working path.");
 
+        mreg.register("CurrentSnapshotTotalSize", () -> {
+            SnapshotFutureTask task = currentSnapshotTask();
+
+            if (task == null)
+                return -1;
+
+            return task.totalSize();

Review Comment:
   ```suggestion
               return task == null ? -1 : task.totalSize();
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@ignite.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org