tuning full production of content
authorrk <rk>
Mon, 18 Feb 2002 10:57:58 +0000 (10:57 +0000)
committerrk <rk>
Mon, 18 Feb 2002 10:57:58 +0000 (10:57 +0000)
source/mircoders/producer/ProducerContent.java

index 21b025e..56766c1 100755 (executable)
@@ -119,9 +119,11 @@ public class ProducerContent extends Producer {
     }
     // timing and message to browser
     long overall = System.currentTimeMillis() - startTime;
-    long ppm = pageCount / (overall/60000);
+    long pagesPerMinute=0, perMinute = overall/60000;
+    if (perMinute >0) pagesPerMinute = pageCount / perMinute;
+
     logHTML(htmlout, "Producer.Content finished producing: " +
-            overall + " ms for "+ pageCount+" Pages = " +ppm + " pages/min");
+            overall + " ms for "+ pageCount+" Pages = " +pagesPerMinute + " pages/min");
     logHTML(htmlout, "Back to <a href=\""+actionRoot+"\">Admin-Startage</a>");
 
     /** @todo why no syncing here? */