Skip to content

Commit 485b9a6

Browse files
genegrCopilot
andauthored
Apply suggestion from @Copilot
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 618e00b commit 485b9a6

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

  • plugins/storage/volume/flasharray/src/main/java/org/apache/cloudstack/storage/datastore/adapter/flasharray

plugins/storage/volume/flasharray/src/main/java/org/apache/cloudstack/storage/datastore/adapter/flasharray/FlashArrayAdapter.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -202,10 +202,11 @@ public void detach(ProviderAdapterContext context, ProviderAdapterDataObject dat
202202
public void delete(ProviderAdapterContext context, ProviderAdapterDataObject dataObject) {
203203
String fullName = normalizeName(pod, dataObject.getExternalName());
204204

205-
// Snapshots live under /volume-snapshots and have the reserved form
206-
// <volume>.<suffix>: the FlashArray rejects renames to any name that
207-
// includes '.' or is not pure alphanumeric+'_'+'-', so we cannot
208-
// tag them with a timestamp on the way out. Just mark them destroyed.
205+
// Snapshots live under /volume-snapshots and already use the reserved
206+
// form <volume>.<suffix>. FlashArray snapshot rename constraints do
207+
// not let us rename them to an arbitrary timestamp-suffixed name
208+
// before deletion, so unlike volumes we skip rename and only mark
209+
// them destroyed.
209210
if (dataObject.getType() == ProviderAdapterDataObject.Type.SNAPSHOT) {
210211
try {
211212
FlashArrayVolume destroy = new FlashArrayVolume();

0 commit comments

Comments
 (0)