Process configuration information.

@param properties
322451
private synchronized void processConfig(boolean updateSSLConfigManager) {
        if (componentContext == null) {
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "Not yet activated, can not process config");
            }
            return;
        }
        if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
            Tr.event(tc, "Processing configuration " + updateSSLConfigManager);
        }

        boolean isServer = locSvc.resolveString(WsLocationConstants.SYMBOL_PROCESS_TYPE).equals(WsLocationConstants.LOC_PROCESS_TYPE_SERVER);

        Dictionary<String, Object> serviceProps = new Hashtable<String, Object>(config);
        serviceProps.put(REPERTOIRE_IDS, repertoireMap.keySet().toArray(new String[repertoireMap.size()]));
        serviceProps.put(KEYSTORE_IDS, keystoreIdMap.keySet().toArray(new String[keystoreIdMap.size()]));
        serviceProps.put(REPERTOIRE_PIDS, repertoirePIDMap.keySet().toArray(new String[repertoirePIDMap.size()]));
        if (updateSSLConfigManager) {
            try {
                // pass reinitialize=true to redo config
                SSLConfigManager.getInstance().initializeSSL(getGlobalProps(),
                                                             true,
                                                             isServer,
                                                             transportSecurityEnabled,
                                                             repertoirePIDMap);
            } catch (SSLException e) {
                if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
                    Tr.event(tc, "Exception processing SSL configuration; " + e);
                }
            }
        }
        if (!repertoireMap.isEmpty() && !keystoreIdMap.isEmpty()) {
            serviceProps.put(SSL_SUPPORT_KEY, SSL_SUPPORT_VALUE_ACTIVE);
        }

        this.componentContext.setServiceProperties(serviceProps);
    }
680686
public void setConfiguredProperties(BeanConfiguration configuration) {
        boolean changed = false;
        final Set<ConfiguredPropertyDescriptor> properties = getDescriptor().getConfiguredProperties();
        for (ConfiguredPropertyDescriptor property : properties) {
            final Object value = configuration.getProperty(property);
            final boolean changedValue = setConfiguredPropertyIfChanged(property, value);
            if (changedValue) {
                changed = true;
            }
        }
        if (changed) {
            onConfigurationChanged();
        }
    }
1146427
function processShorthandPropertyConfiguration () {

  // Fetch extensions implementing .processShorthandPropertyConfiguration(...) method
  let extensions = _.filter(this.extensions, (extension) => {
    return extension.implemented.processShorthandPropertyConfiguration;
  });

  // Create a proxy .processShorthandPropertyConfiguration(...) method
  this.processShorthandPropertyConfiguration =  (propertyConfiguration) => {
    // Execute all extensions' .processShorthandPropertyConfiguration(...) method and update configuration
    _.forEach(extensions, (extension) => {
      propertyConfiguration = extension.processShorthandPropertyConfiguration(propertyConfiguration);
    });
    // Return updated configuration
    return propertyConfiguration;
  };

}
1065986
public void storeProperties(Map<String, String> properties) throws IOException {
        Properties props = new Properties();
        properties.forEach(props::setProperty);
        try (FileOutputStream out = new FileOutputStream(getPropertiesFile())) {
            props.store(out, "");
        }
    }
1079968
void setup(final Map<String, Object> properties) {
        final List<SetupAction> successfulActions = new ArrayList<SetupAction>();
        for (final SetupAction action : setupActions) {
            try {
                action.setup(properties);
                successfulActions.add(action);
            } catch (final Throwable e) {
                for (SetupAction s : successfulActions) {
                    try {
                        s.teardown(properties);
                    } catch (final Throwable t) {
                        // we ignore these, and just propagate the exception that caused the setup to fail
                    }
                }
                throw new RuntimeException(e);
            }
        }
    }
551059
private void processConfigProps(Map<String, Object> props) {
        if (props == null || props.isEmpty())
            return;
        id = (String) props.get(CFG_KEY_ID);
        if (id == null) {
            Tr.error(tc, "AUTHZ_ROLE_ID_IS_NULL");
            return;
        }
        rolePids = (String[]) props.get(CFG_KEY_ROLE);
//        if (rolePids == null || rolePids.length < 1)
//            return;
        processRolePids();
    }
333178
public static void init() {

        // Get configuration

        // Read from "server.properties" or custom file.
        String configFile = null;
        Properties serverProperties = new Properties();
        try {
            configFile = System.getProperty(PROPERTY_PREFIX + "config", "server.properties");
            LOG.info("Loading server configuration from " + configFile);

            try (InputStream is = new FileInputStream(configFile)) {
                serverProperties.load(is);
            }

        } catch (FileNotFoundException e) {
            LOG.warn(configFile + " not found.");
        } catch (IOException e) {
            LOG.error("Unexpected error reading " + configFile);
        }

        init(serverProperties);
    }
1048654
@SuppressWarnings("unchecked")
    public void raConfigure(ConfigProperties properties) {
        String httpClientFactoryClassName = (String) properties.getProperty(CFG_PROPERTY_HTTP_CLIENT_FACTORY)
                .getValue();
        if (httpClientFactoryClassName.isEmpty()) {
            maxTotal = (Integer) properties.getProperty(CFG_PROPERTY_MAX_CONNECTIONS_TOTAL).getValue();

            maxForRoutes = new HashMap<HttpRoute, Integer>();

            defaultMaxForRoute = (Integer) properties.getProperty(CFG_PROPERTY_DEFAULT_MAX_FOR_ROUTE).getValue();

            String maxForRoutesString = (String) properties.getProperty(CFG_PROPERTY_MAX_CONNECTIONS_FOR_ROUTES)
                    .getValue();

            String[] maxForRoutesStrings = maxForRoutesString.split(",");

            for (String maxForRoute : maxForRoutesStrings) {
                if (maxForRoute.isEmpty()) {
                    continue;
                }
                String[] maxForRouteParts = maxForRoute.split(":");

                String scheme = maxForRouteParts[HTTP_SCHEME_INDEX];
                if (scheme == null || scheme.equals("")) {
                    scheme = HttpHost.DEFAULT_SCHEME_NAME;
                }

                String host = maxForRouteParts[HTTP_HOST_INDEX];

                String portStr = maxForRouteParts[HTTP_PORT_INDEX];
                if (portStr == null || portStr.equals("")) {
                    portStr = "80";
                }

                int port = Integer.parseInt(portStr);

                String maxForRoutePartsStr = maxForRouteParts[HTTP_MAXFORROUTE_INDEX];
                Integer max = Integer.valueOf(maxForRoutePartsStr);

                HttpRoute httpRoute = new HttpRoute(new HttpHost(host, port, scheme));

                maxForRoutes.put(httpRoute, max);
            }
        } else {
            try {
                httpClientFactory = ((Class<? extends HttpClientFactory>) Class.forName(httpClientFactoryClassName))
                        .newInstance();
            } catch (Exception e) {
                tracer.severe("failed to load http client factory class", e);
            }
        }
    }
1323760
private void startConfiguration(Properties properties) {

        if (properties.containsKey(Configurator.ROOT_LOGGER_KEY)) {
            Log.i(TAG, "Modern configuration not yet supported");
        } else {
            Log.i(TAG, "Configure using the simple style (aka classic style)");
            configureSimpleStyle(properties);
        }
    }
352417
public void putProperties(Map<String, String> properties) {
		for (Map.Entry<String, String> property : properties.entrySet()) {
			put(property.getKey(), property.getValue());
		}
	}
779717
@Override
    public void setProperties(Properties properties) {
        if (this.env == null) {
            this.env = properties;
        } else {
            this.env.putAll(properties);
        }

        if (baseGateway != null) {
            baseGateway.setProperties(properties);
        }
    }
264092
public void setProperties(Properties properties) throws ConfigurationException {
		String dbDriver = properties.getProperty("dbdriver").toString();
		if (dbDriver == null) {
			throw new ConfigurationException("please specify dbDriver for connectionpool");
		}

		dbUrl = properties.getProperty("dburl").toString();
		dbUsername = properties.getProperty("dbusername").toString();
		dbUserpassword = properties.getProperty("dbuserpassword").toString();

		if (properties.getProperty("nrof_connections") != null) {
			initialNrofConnections = Integer.valueOf(properties.getProperty("nrof_connections"));
			maxNrofConnections = Integer.valueOf(properties.getProperty("nrof_connections"));
		} else {
			initialNrofConnections = Integer.valueOf(properties.getProperty("initial_nrof_connections", "" + initialNrofConnections));
			maxNrofConnections = Integer.valueOf(properties.getProperty("max_nrof_connections", "" + maxNrofConnections));
			//set default option
			//properties.getProperty("nrof_connections", new GenericValue(initialNrofConnections)).toInteger().intValue();
		}
		connectionRequestTimeout = Integer.valueOf(properties.getProperty("connection_request_timeout", "" + connectionRequestTimeout));
		connectionTimeout = Integer.valueOf(properties.getProperty("connection_timeout", "" + connectionTimeout));
		connectionTimeoutCheck = Integer.valueOf(properties.getProperty("connection_timeout_check_interval", "" + connectionTimeoutCheck));

		connectionTestStatement = properties.getProperty("connection_test_statement", connectionTestStatement).toString();

		createReadOnlyConnections = Boolean.valueOf(properties.getProperty("create_readonly_connections", "" + createReadOnlyConnections));
		defaultIsolationLevel = isolationLevelStrings.indexOf(properties.getProperty("default_isolaton_level", "" + defaultIsolationLevel));

		try {
			Class.forName(dbDriver);
			Enumeration drivers = DriverManager.getDrivers();

			driverInfo = "";
			int count = 0;
			while (drivers.hasMoreElements()) {
				count++;
				Driver driver = (Driver) drivers.nextElement();
				driverInfo += "driver " + count + ": " + driver.getMajorVersion() + '.' + driver.getMinorVersion() + "\n";
			}
		} catch (ClassNotFoundException cnfe) {
			throw new ConfigurationException("ERROR: Driver \"" + dbDriver + "\" not found...");
		}
		resetStatistics();
	}
1208791
protected void processProperties(Properties properties) throws ParseException
    {
        if (properties == null)
        {
            return;
        }

        for (Enumeration<?> e = properties.propertyNames(); e.hasMoreElements();)
        {
            String option = e.nextElement().toString();
            
            Option opt = options.getOption(option);
            if (opt == null)
            {
                throw new UnrecognizedOptionException("Default option wasn't defined", option);
            }
            
            // if the option is part of a group, check if another option of the group has been selected
            OptionGroup group = options.getOptionGroup(opt);
            boolean selected = group != null && group.getSelected() != null;
            
            if (!cmd.hasOption(option) && !selected)
            {
                // get the value from the properties instance
                String value = properties.getProperty(option);

                if (opt.hasArg())
                {
                    if (opt.getValues() == null || opt.getValues().length == 0)
                    {
                        try
                        {
                            opt.addValueForProcessing(value);
                        }
                        catch (RuntimeException exp) //NOPMD
                        {
                            // if we cannot add the value don't worry about it
                        }
                    }
                }
                else if (!("yes".equalsIgnoreCase(value)
                        || "true".equalsIgnoreCase(value)
                        || "1".equalsIgnoreCase(value)))
                {
                    // if the value is not yes, true or 1 then don't add the
                    // option to the CommandLine
                    continue;
                }

                cmd.addOption(opt);
                updateRequiredOptions(opt);
            }
        }
    }
157206
protected void processProperties(ConfigurableListableBeanFactory beanFactoryToProcess, Properties props)
            throws BeansException {

        BeanDefinitionVisitor visitor =
                new ReloadingPropertyPlaceholderConfigurer.PlaceholderResolvingBeanDefinitionVisitor(props);
        String[] beanNames = beanFactoryToProcess.getBeanDefinitionNames();
        for (int i = 0; i < beanNames.length; i++) {
            // Check that we're not parsing our own bean definition,
            // to avoid failing on unresolvable placeholders in net.unicon.iamlabs.spring.properties.example.net
            // .unicon.iamlabs.spring.properties file locations.
            if (!(beanNames[i].equals(this.beanName) && beanFactoryToProcess.equals(this.beanFactory))) {
                this.currentBeanName = beanNames[i];
                try {
                    BeanDefinition bd = beanFactoryToProcess.getBeanDefinition(beanNames[i]);
                    try {
                        visitor.visitBeanDefinition(bd);
                    } catch (BeanDefinitionStoreException ex) {
                        throw new BeanDefinitionStoreException(bd.getResourceDescription(), beanNames[i],
                                ex.getMessage());
                    }
                } finally {
                    currentBeanName = null;
                }
            }
        }

        StringValueResolver stringValueResolver = new PlaceholderResolvingStringValueResolver(props);

        // New in Spring 2.5: resolve placeholders in alias target names and aliases as well.
        beanFactoryToProcess.resolveAliases(stringValueResolver);

        // New in Spring 3.0: resolve placeholders in embedded values such as annotation attributes.
        beanFactoryToProcess.addEmbeddedValueResolver(stringValueResolver);
    }
768163
private void processPropertyOverrides() {
    PropertyOverrides propertyOverrides = entityClass.getAnnotation(PropertyOverrides.class);
    if (propertyOverrides == null) {
      return;
    }
    PropertyOverride[] propertyOverridesArray = propertyOverrides.value();
    for (PropertyOverride propertyOverride : propertyOverridesArray) {
      entityMetadata.putPropertyOverride(propertyOverride);
    }
  }
680131
public void setProperties( Map<String,String> properties ) {
        Map<String,String> userProperties = systemSession.getUserProperties();
        if ( userProperties == null ) {
            userProperties = new HashMap<String,String>();
        }
        userProperties.putAll( properties );
        
        log.debug( "Session userProperties: {}", userProperties );
        
        systemSession = (MavenRepositorySystemSession)systemSession.setUserProperties( userProperties );
        
    }
260949
public void applyProperties(Map properties) {
        if (properties.containsKey("enabled")) {
            setEnabled(!"false".equalsIgnoreCase
                       ((String)properties.get("enabled")));
        }

        if (properties.containsKey("debug")) {
            setDebugEnabled(!"false".equalsIgnoreCase
                            ((String)properties.get("debug")));
        }

        if (properties.containsKey("info")) {
            setInfoEnabled(!"false".equalsIgnoreCase
                           ((String)properties.get("info")));
        }

        if (properties.containsKey("warn")) {
            setWarnEnabled(!"false".equalsIgnoreCase
                           ((String)properties.get("warn")));
        }

        if (properties.containsKey("error")) {
            setErrorEnabled(!"false".equalsIgnoreCase
                            ((String)properties.get("error")));
        }
    }