From f639f56834d563b01b1699568aa94d30908e6a06 Mon Sep 17 00:00:00 2001 From: DK101010 <57522802+DK101010@users.noreply.github.com> Date: Thu, 20 Jan 2022 14:54:26 +0100 Subject: [PATCH] fill volume attached field (#5865) Co-authored-by: DK101010 --- .../cloudstack/engine/orchestration/VolumeOrchestrator.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java b/engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java index 3b9397782f5..d88e17d98ec 100644 --- a/engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java +++ b/engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java @@ -164,6 +164,7 @@ import com.cloud.vm.dao.UserVmCloneSettingDao; import com.cloud.vm.dao.UserVmDao; import static com.cloud.storage.resource.StorageProcessor.REQUEST_TEMPLATE_RELOAD; +import java.util.Date; public class VolumeOrchestrator extends ManagerBase implements VolumeOrchestrationService, Configurable { @@ -1975,6 +1976,7 @@ public class VolumeOrchestrator extends ManagerBase implements VolumeOrchestrati vol.setPath(path); vol.setChainInfo(chainInfo); vol.setState(Volume.State.Ready); + vol.setAttached(new Date()); vol = _volsDao.persist(vol); return toDiskProfile(vol, offering); }