Package org.jboss.cache.config

Examples of org.jboss.cache.config.ConfigurationException


      if (existsAttribute(ignoreModifications)) iclc.setIgnoreModifications(getBoolean(ignoreModifications));
      String purgeOnStartup = getAttributeValue(indivElement, "purgeOnStartup");
      if (existsAttribute(purgeOnStartup)) iclc.setPurgeOnStartup(getBoolean(purgeOnStartup));
      String clClass = getAttributeValue(indivElement, "class");
      if (!existsAttribute(clClass))
         throw new ConfigurationException("Missing 'class'  attribute for cache loader configuration");
      iclc.setClassName(clClass);
      iclc.setProperties(XmlConfigHelper.readPropertiesContents(indivElement, "properties"));
      CacheLoaderConfig.IndividualCacheLoaderConfig.SingletonStoreConfig ssc = parseSingletonStoreConfig(getSingleElementInCoreNS("singletonStore", indivElement));
      if (ssc != null)
      {
View Full Code Here


      for (int i = 0; i < nodesToPreload.getLength(); i++)
      {
         Element node = (Element) nodesToPreload.item(i);
         String fqn2preload = getAttributeValue(node, "fqn");
         if (!existsAttribute(fqn2preload))
            throw new ConfigurationException("Missing 'fqn' attribute in 'preload' element");
         if (i > 0) result.append(",");
         result.append(fqn2preload);
      }
      //no elements defined for preload so by default load the root
      if (nodesToPreload.getLength() == 0)
View Full Code Here

   public void validate() throws ConfigurationException
   {
      super.validate();
      if (maxElementsPerNode < 0)
      {
         throw new ConfigurationException("maxElementsPerNode must be must be " +
               "configured to a value greater than or equal to 0");
      }
   }
View Full Code Here

    */
   @Override
   public void validate() throws ConfigurationException
   {
      if (getMaxNodes() < 0)
         throw new ConfigurationException("maxNodes not configured");
   }
View Full Code Here

   @Override
   public void validate() throws ConfigurationException
   {
      super.validate();
      if (getMaxNodes() < 0)
         throw new ConfigurationException("maxNodes not configured");
   }
View Full Code Here

   @Override
   public void validate() throws ConfigurationException
   {
      if (timeToLiveSeconds < 0)
      {
         throw new ConfigurationException("timeToLive must be " +
               "configured to a value greater than or equal to 0 for " + getEvictionPolicyClass());
      }
   }
View Full Code Here

   public void validate() throws ConfigurationException
   {
      super.validate();
      if (getMaxNodes() < 0)
      {
         throw new ConfigurationException("maxNodes must be must be " +
               "configured to a value greater than or equal to 0");
      }
   }
View Full Code Here

   private void assertNotSingletonAndShared(IndividualCacheLoaderConfig cfg)
   {
      SingletonStoreConfig ssc = cfg.getSingletonStoreConfig();
      if (ssc != null && ssc.isSingletonStoreEnabled() && config.isShared())
         throw new ConfigurationException("Invalid cache loader configuration!!  If a cache loader is configured as a singleton, the cache loader cannot be shared in a cluster!");
   }
View Full Code Here

      {
         el = XmlConfigHelper.stringToElementInCoreNS(xml);
      }
      catch (Exception e)
      {
         throw new ConfigurationException(e);
      }
      EvictionConfig cfg = parser.parseEvictionElement(el);
      if (validate)
      {
         cfg.getDefaultEvictionRegionConfig().validate();
View Full Code Here

         if (fqn.equals(DEFAULT_REGION) || fqn.isRoot())
         {
            if (setDefault)
            {
               throw new ConfigurationException("A default region for evictions has already been set for this cache");
            }
            if (trace) log.trace("Applying settings for default region to Fqn.ROOT");
            fqn = Fqn.ROOT;
            setDefault = true;
         }
View Full Code Here

TOP

Related Classes of org.jboss.cache.config.ConfigurationException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.