geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hogst...@apache.org
Subject svn commit: r558520 - /geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java
Date Sun, 22 Jul 2007 18:22:07 GMT
Author: hogstrom
Date: Sun Jul 22 11:22:06 2007
New Revision: 558520

URL: http://svn.apache.org/viewvc?view=rev&rev=558520
Log:
Modified default Users and Quotes to 200 / 400 respectively.

Added a new property that will control the frequency of the market summary 
operation.  The meaning of the values are:

  -1 means every operation
   0 means never
 > 0 means number of millseconds between summaries.  These will be 
     synchronized so only one tran in this period will create a summary and will
     cache its results.

Modified:
    geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java

Modified: geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java
URL: http://svn.apache.org/viewvc/geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java?view=diff&rev=558520&r1=558519&r2=558520
==============================================================================
--- geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java
(original)
+++ geronimo/daytrader/trunk/modules/ejb/src/main/java/org/apache/geronimo/samples/daytrader/TradeConfig.java
Sun Jul 22 11:22:06 2007
@@ -72,8 +72,8 @@
 	public static int cachingType = NO_CACHING;
 	
 	/* Trade Database Scaling parameters*/
-	private static int MAX_USERS = 50;
-	private static int MAX_QUOTES = 100;
+	private static int MAX_USERS = 200;
+	private static int MAX_QUOTES = 400;
 
 	/* Trade Database specific paramters */
 	public static String JDBC_UID = null;
@@ -109,6 +109,7 @@
 	private static int primIterations = 1;
 	private static boolean longRun = true;
 	private static boolean publishQuotePriceChange = false;
+	private static long  marketSummaryInterval = 60000;
 
 	/*
 	 * Penny stocks is a problem where the random price change factor gets a stock
@@ -859,6 +860,14 @@
     
     public static boolean getPublishQuotePriceChange() {
         return publishQuotePriceChange;
+    }
+
+    public static void setMarketSummaryInterval(long millis) {
+        TradeConfig.marketSummaryInterval = millis;
+    }
+    
+    public static long getMarketSummaryInterval() {
+        return marketSummaryInterval;
     }
 
 



Mime
View raw message