Revision: 18163
          http://sourceforge.net/p/gate/code/18163
Author:   johann_p
Date:     2014-07-07 18:46:57 +0000 (Mon, 07 Jul 2014)
Log Message:
-----------
Add some information about total and used memory before
and after loading the application to the log.

Modified Paths:
--------------
    gcp/trunk/src/gate/cloud/batch/BatchRunner.java

Modified: gcp/trunk/src/gate/cloud/batch/BatchRunner.java
===================================================================
--- gcp/trunk/src/gate/cloud/batch/BatchRunner.java     2014-07-07 18:36:36 UTC 
(rev 18162)
+++ gcp/trunk/src/gate/cloud/batch/BatchRunner.java     2014-07-07 18:46:57 UTC 
(rev 18163)
@@ -643,7 +643,12 @@
         }
       }
     });
-    
+
+    final int MB = 1024*1024;
+    Runtime runtime = Runtime.getRuntime();
+    log.info("Initial total allocated memory: 
"+(runtime.totalMemory()/MB)+"M");
+    log.info("Initial used memory: 
"+((runtime.totalMemory()-runtime.freeMemory())/MB)+"M");
+
     try {
       // we set  gate home differently depending on which invocation mode
       // we have: if we got invoked from gcpcli, we want to use the gate
@@ -772,7 +777,8 @@
           aBatch.init();
         }
       }
-      
+      log.info("Total allocated memory: "+(runtime.totalMemory()/MB)+"M");
+      log.info("Used memory: 
"+((runtime.totalMemory()-runtime.freeMemory())/MB)+"M");
       log.info("Launching batch:\n" + aBatch);
       instance.runBatch(aBatch);
       instance.shutdownWhenFinished(true);

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs

Reply via email to