use of com.baidu.disconf.core.common.constants.DisConfigTypeEnum in project disconf by knightliao.
the class ConfigMgrImpl method getConfVoWithZk.
/**
* 根据 配置ID获取ZK对比数据
*/
@Override
public MachineListVo getConfVoWithZk(Long configId) {
Config config = configDao.get(configId);
App app = appMgr.getById(config.getAppId());
Env env = envMgr.getById(config.getEnvId());
//
//
//
DisConfigTypeEnum disConfigTypeEnum = DisConfigTypeEnum.FILE;
if (config.getType().equals(DisConfigTypeEnum.ITEM.getType())) {
disConfigTypeEnum = DisConfigTypeEnum.ITEM;
}
ZkDisconfData zkDisconfData = zkDeployMgr.getZkDisconfData(app.getName(), env.getName(), config.getVersion(), disConfigTypeEnum, config.getName());
if (zkDisconfData == null) {
return new MachineListVo();
}
MachineListVo machineListVo = getZkData(zkDisconfData.getData(), config);
return machineListVo;
}
Aggregations