[jboss-cvs] JBossCache/src/org/jboss/cache/config ...

Manik Surtani msurtani at jboss.com
Mon Oct 23 13:39:00 EDT 2006


  User: msurtani
  Date: 06/10/23 13:39:00

  Modified:    src/org/jboss/cache/config  EvictionConfig.java
  Log:
  JBCACHE-684
  
  Revision  Changes    Path
  1.2       +25 -1     JBossCache/src/org/jboss/cache/config/EvictionConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/EvictionConfig.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- EvictionConfig.java	23 Oct 2006 05:46:39 -0000	1.1
  +++ EvictionConfig.java	23 Oct 2006 17:39:00 -0000	1.2
  @@ -18,7 +18,8 @@
      private static final long serialVersionUID = -7979639000026975201L;
      
      private String defaultEvictionPolicyClass;
  -   private int wakeupIntervalSeconds = EvictionConfiguration.WAKEUP_DEFAULT;;
  +   private int wakeupIntervalSeconds = EvictionConfiguration.WAKEUP_DEFAULT;
  +   private int eventQueueSize = EvictionConfiguration.EVENT_QUEUE_SIZE_DEFAULT; // defaults to the 'old' hard-coded value of 200000
      private List evictionRegionConfigs;
      
      public EvictionConfig() {}
  @@ -46,6 +47,18 @@
            if (wakeupIntervalSeconds <= 0)
               wakeupIntervalSeconds = EvictionConfiguration.WAKEUP_DEFAULT;
      
  +
  +         temp = XmlHelper.getTagContents(element,
  +                 EvictionConfiguration.EVENT_QUEUE_SIZE, EvictionConfiguration.ATTR, EvictionConfiguration.NAME);
  +
  +         if (temp != null)
  +         {
  +            eventQueueSize = Integer.parseInt(temp);
  +         }
  +
  +         if (eventQueueSize <= 0) eventQueueSize = EvictionConfiguration.EVENT_QUEUE_SIZE_DEFAULT;
  +
  +   
            NodeList list = element.getElementsByTagName(EvictionConfiguration.REGION);
            List regionConfigs = new ArrayList(list.getLength());
            for (int i = 0; i < list.getLength(); i++)
  @@ -89,6 +102,17 @@
         return evictionRegionConfigs;
      }
   
  +
  +   public int getEventQueueSize()
  +   {
  +      return eventQueueSize;
  +   }
  +
  +   public void setEventQueueSize(int eventQueueSize)
  +   {
  +      this.eventQueueSize = eventQueueSize;
  +   }
  +
      public void setEvictionRegionConfigs(List evictionRegionConfigs)
      {
         testImmutability("evictionRegionConfigs");
  
  
  



More information about the jboss-cvs-commits mailing list