ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [18/50] [abbrv] ignite git commit: Fixed IGFS max size.
Date Thu, 07 Jul 2016 06:01:43 GMT
 Fixed IGFS max size.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/583ef2ed
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/583ef2ed
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/583ef2ed

Branch: refs/heads/ignite-1232
Commit: 583ef2edbc3b05c65d794611553e8a7ff0a83619
Parents: 860167c
Author: vsisko <vsisko@gridgain.com>
Authored: Tue Jul 5 00:21:56 2016 +0700
Committer: Alexey Kuznetsov <akuznetsov@apache.org>
Committed: Tue Jul 5 00:21:56 2016 +0700

----------------------------------------------------------------------
 .../org/apache/ignite/internal/visor/igfs/VisorIgfs.java |  2 +-
 .../ignite/internal/visor/igfs/VisorIgfsMetrics.java     | 11 +++++++----
 2 files changed, 8 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/583ef2ed/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfs.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfs.java
b/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfs.java
index 29c79fe..114d92d 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfs.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfs.java
@@ -72,7 +72,7 @@ public class VisorIgfs implements Serializable, LessNamingBean {
         return new VisorIgfs(
             igfs.name(),
             igfs.configuration().getDefaultMode(),
-            VisorIgfsMetrics.from(igfs.metrics()),
+            VisorIgfsMetrics.from(igfs),
             igfs.configuration().getSecondaryFileSystem() != null
         );
     }

http://git-wip-us.apache.org/repos/asf/ignite/blob/583ef2ed/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfsMetrics.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfsMetrics.java
b/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfsMetrics.java
index af7af06..58acee1 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfsMetrics.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/visor/igfs/VisorIgfsMetrics.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.internal.visor.igfs;
 
 import java.io.Serializable;
+import org.apache.ignite.IgniteFileSystem;
 import org.apache.ignite.igfs.IgfsMetrics;
 import org.apache.ignite.internal.LessNamingBean;
 import org.apache.ignite.internal.util.typedef.internal.S;
@@ -72,15 +73,17 @@ public class VisorIgfsMetrics implements Serializable, LessNamingBean
{
     private long bytesWrtTm;
 
     /**
-     * @param m IGFS metrics.
+     * @param igfs Source IGFS.
      * @return Data transfer object for given IGFS metrics.
      */
-    public static VisorIgfsMetrics from(IgfsMetrics m) {
-        assert m != null;
+    public static VisorIgfsMetrics from(IgniteFileSystem igfs) {
+        assert igfs != null;
+
+        IgfsMetrics m = igfs.metrics();
 
         VisorIgfsMetrics metrics = new VisorIgfsMetrics();
 
-        metrics.totalSpaceSz = m.maxSpaceSize();
+        metrics.totalSpaceSz = igfs.configuration().getMaxSpaceSize();
         metrics.usedSpaceSz = m.localSpaceSize();
         metrics.foldersCnt = m.directoriesCount();
         metrics.filesCnt = m.filesCount();


Mime
View raw message