use of com.baiyi.opscloud.common.datasource.AliyunConfig in project opscloud4 by ixrjog.
the class AliyunLogFacadeImpl method pushLogMemberById.
@Override
public void pushLogMemberById(Integer id) {
AliyunLogMember aliyunLogMember = aliyunLogMemberService.getById(id);
if (aliyunLogMember == null)
return;
AliyunLogMemberVO.LogMember logMember = BeanCopierUtil.copyProperties(aliyunLogMember, AliyunLogMemberVO.LogMember.class);
aliyunLogMemberPacker.wrap(logMember, SimpleExtend.EXTEND);
AliyunConfig aliyunDsInstanceConfig = (AliyunConfig) getConfig(logMember.getLog().getDatasourceInstanceId());
MachineGroup machineGroup = aliyunLogMachineGroupHandler.getMachineGroup(aliyunDsInstanceConfig.getAliyun(), logMember.getLog().getProject(), logMember.getServerGroupName());
if (machineGroup == null) {
// 创建
aliyunLogMachineGroupHandler.createMachineGroup(aliyunDsInstanceConfig.getAliyun(), logMember);
} else {
// 更新
aliyunLogMachineGroupHandler.updateMachineGroup(aliyunDsInstanceConfig.getAliyun(), logMember);
}
updateAliyunLogMemberLastPushTime(aliyunLogMember);
}
use of com.baiyi.opscloud.common.datasource.AliyunConfig in project opscloud4 by ixrjog.
the class AssetToResourceAccessManagementConverter method wrap.
@Override
protected void wrap(AccessManagementVO.XAccessManagement xam, DatasourceConfig datasourceConfig) {
AliyunConfig config = dsConfigHelper.build(datasourceConfig, AliyunConfig.class);
xam.setLoginUser(Joiner.on("").join(xam.getUsername(), config.getAliyun().getAccount().getDomain()));
xam.setLoginUrl(config.getAliyun().getAccount().getLoginUrl());
}
use of com.baiyi.opscloud.common.datasource.AliyunConfig in project opscloud4 by ixrjog.
the class AliyunDmsTest method listUserTest.
@Test
void listUserTest() {
AliyunConfig config = getConfig();
try {
List<DmsUser.User> users = AliyunDmsUserDriver.listUser(config.getAliyun());
System.out.println(users);
} catch (Exception e) {
}
}
use of com.baiyi.opscloud.common.datasource.AliyunConfig in project opscloud4 by ixrjog.
the class AliyunLogTest method listProjectTest.
@Test
void listProjectTest() {
AliyunConfig aliyunDsInstanceConfig = (AliyunConfig) getConfig();
List<Project> projects = aliyunLogHandler.listProject(aliyunDsInstanceConfig.getAliyun(), "");
System.out.println(projects);
}
Aggregations