添加日志

develop
bayuzhen 2024-05-24 12:04:32 +08:00
parent 2647af89aa
commit 12dac071a5
2 changed files with 3 additions and 0 deletions

View File

@ -706,6 +706,7 @@ public class VmwareTransporter implements ResourceTransporter {
for (CloudServer cloudServer : cloudServers) {
CloudServer server = cloudServerRepository.getByInstanceId(cloudServer.getInstanceId());
VmResourcePool vmResourcePool = resourcePoolRepository.queryByPoolVal(cloudServer.getResPoolVal(), vdcId);
log.info("虚拟机信息:" + JSONObject.toJSONString(server));
if (null != vmResourcePool && null != server) {
server.setResPoolId(vmResourcePool.getId());
cloudServerRepository.update(server);

View File

@ -406,6 +406,7 @@ public class SyncVmwareUtils {
}
log.info("更新旧虚拟机:{}", oldServer.getId());
log.info("虚拟机信息:" + JSONObject.toJSONString(oldServer));
cloudServerRepository.update(oldServer);
log.info("更新旧虚拟机完成:{}", oldServer.getId());
Long serverId = oldServer.getId();
@ -694,6 +695,7 @@ public class SyncVmwareUtils {
cloudServer.setResourceId(IDFactory.instance().uuid());
cloudServer.setRecycle(false);
cloudServer.setCatalog(Catalog.Manager);
log.info("虚拟机信息:" + JSONObject.toJSONString(cloudServer));
cloudServerRepository.save(cloudServer);
Long serverId = cloudServer.getId();
if (cloudServer.getIsTemplate()) {