Search in sources :

Example 1 with ConfigurationBackedDynamicPropertySupportImpl

use of com.netflix.config.ConfigurationBackedDynamicPropertySupportImpl in project java-chassis by ServiceComb.

the class TestLoadbalanceHandler method beforeCls.

@BeforeClass
public static void beforeCls() {
    AbstractConfiguration configuration = new BaseConfiguration();
    DynamicPropertyFactory.initWithConfigurationSource(new ConfigurationBackedDynamicPropertySupportImpl(configuration));
    configuration.addProperty("cse.loadbalance.test.transactionControl.policy", "io.servicecomb.loadbalance.filter.SimpleTransactionControlFilter");
    configuration.addProperty("cse.loadbalance.test.transactionControl.options.tag0", "value0");
    configuration.addProperty("cse.loadbalance.test.isolation.enabled", "true");
}
Also used : AbstractConfiguration(org.apache.commons.configuration.AbstractConfiguration) BaseConfiguration(org.apache.commons.configuration.BaseConfiguration) ConfigurationBackedDynamicPropertySupportImpl(com.netflix.config.ConfigurationBackedDynamicPropertySupportImpl) BeforeClass(org.junit.BeforeClass)

Aggregations

ConfigurationBackedDynamicPropertySupportImpl (com.netflix.config.ConfigurationBackedDynamicPropertySupportImpl)1 AbstractConfiguration (org.apache.commons.configuration.AbstractConfiguration)1 BaseConfiguration (org.apache.commons.configuration.BaseConfiguration)1 BeforeClass (org.junit.BeforeClass)1