All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.nutz.boot.starter.apollo.ApolloConfigureLoader Maven / Gradle / Ivy

There is a newer version: 2.5.1.v20220215
Show newest version
package org.nutz.boot.starter.apollo;

import org.nutz.boot.config.impl.AbstractConfigureLoader;
import org.nutz.ioc.impl.PropertiesProxy;

import com.ctrip.framework.apollo.Config;
import com.ctrip.framework.apollo.ConfigService;

public class ApolloConfigureLoader extends AbstractConfigureLoader {

    public void init() throws Exception {
        Config config = ConfigService.getAppConfig();
        conf = new PropertiesProxy();
        config.getPropertyNames().forEach((key) -> conf.put(key, config.getProperty(key, null)));
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy