Package org.apache.commons.configuration

Examples of org.apache.commons.configuration.PropertiesConfiguration.containsKey()


      List<String> backends = new ArrayList<String>();
      if (numPreferredNodes > 0) {
        /* Attempt to parse the list of slaves, which we'll need to (randomly) select preferred
         * nodes. */
        if (!conf.containsKey(BACKENDS)) {
          LOG.fatal("Missing configuration backend list, which is needed to randomly select " +
                    "preferred nodes (num_preferred_nodes set to " + numPreferredNodes + ")");
        }
        for (String node : conf.getStringArray(BACKENDS)) {
          backends.add(node);
View Full Code Here


          LOG.fatal("Number of backends smaller than number of preferred nodes!");
        }
      }

      List<UserInfo> users = new ArrayList<UserInfo>();
      if (conf.containsKey(USERS)) {
        for (String userSpecification : conf.getStringArray(USERS)) {
          LOG.debug("Reading user specification: " + userSpecification);
          String[] parts = userSpecification.split(":");
          if (parts.length != 3) {
            LOG.error("Unexpected user specification string: " + userSpecification +
View Full Code Here

      List<String> backends = new ArrayList<String>();
      if (numPreferredNodes > 0) {
        /* Attempt to parse the list of slaves, which we'll need to (randomly) select preferred
         * nodes. */
        if (!conf.containsKey(BACKENDS)) {
          LOG.fatal("Missing configuration backend list, which is needed to randomly select " +
                    "preferred nodes (num_preferred_nodes set to " + numPreferredNodes + ")");
        }
        for (String node : conf.getStringArray(BACKENDS)) {
          backends.add(node);
View Full Code Here

          LOG.fatal("Number of backends smaller than number of preferred nodes!");
        }
      }

      List<UserInfo> users = new ArrayList<UserInfo>();
      if (conf.containsKey(USERS)) {
        for (String userSpecification : conf.getStringArray(USERS)) {
          LOG.debug("Reading user specification: " + userSpecification);
          String[] parts = userSpecification.split(":");
          if (parts.length != 3) {
            LOG.error("Unexpected user specification string: " + userSpecification +
View Full Code Here

    public synchronized void start() throws Exception
    {
        if (counter == 0) {
            // Disable extensions manager external repositories
            PropertiesConfiguration properties = loadXWikiPropertiesConfiguration();
            if (!properties.containsKey("extension.repositories")) {
                properties.setProperty("extension.repositories", "");
            }
            saveXWikiProperties(properties);

            super.start();
View Full Code Here

      PropertiesConfiguration properties = new PropertiesConfiguration();
      properties.load(propertiesInputStream);
     
      // TODO: put other useful properties
      properties.setProperty("user.home", System.getProperty("user.home"));
      if(!properties.containsKey("siteUrl")) {
        properties.setProperty("siteUrl", servletContext.getContextPath());
      }
      initDefaultSystemProperties(properties);
     
      copyToSystemProperties(properties);
View Full Code Here

      PropertiesConfiguration properties = new PropertiesConfiguration();
      properties.load(propertiesInputStream);
     
      // TODO: put other useful properties
      properties.setProperty("user.home", System.getProperty("user.home"));
      if(!properties.containsKey("siteUrl")) {
        properties.setProperty("siteUrl", servletContext.getContextPath());
      }
      initDefaultSystemProperties(properties);
     
      copyToSystemProperties(properties);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.