Skip to content

Commit 36c88d1

Browse files
committed
changed the name of the column previous_id to last_id
1 parent e53a1ce commit 36c88d1

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

engine/schema/src/main/java/com/cloud/storage/VolumeVO.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@ public class VolumeVO implements Volume {
4848
@Column(name = "id")
4949
long id;
5050

51-
@Column(name = "previous_id")
52-
private long previousId;
51+
@Column(name = "last_id")
52+
private long lastId;
5353

5454
@Column(name = "name")
5555
String name;
@@ -681,11 +681,11 @@ public void setExternalUuid(String externalUuid) {
681681

682682
public void setEncryptFormat(String encryptFormat) { this.encryptFormat = encryptFormat; }
683683

684-
public long getPreviousId() {
685-
return previousId;
684+
public long getLastId() {
685+
return lastId;
686686
}
687687

688-
public void setPreviousId(long previousId) {
689-
this.previousId = previousId;
688+
public void setLastId(long lastId) {
689+
this.lastId = lastId;
690690
}
691691
}

engine/schema/src/main/resources/META-INF/db/schema-41900to41910.sql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,4 +71,4 @@ UPDATE `cloud`.`configuration` SET
7171
`options` = 'FirstFitRouting,RandomAllocator,TestingAllocator,FirstFitAllocator,RecreateHostAllocator'
7272
WHERE `name` = 'host.allocators.order';
7373

74-
CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('volumes','previous_id', 'bigint(20) unsigned DEFAULT NULL');
74+
CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('volumes','last_id', 'bigint(20) unsigned DEFAULT NULL');

engine/storage/datamotion/src/main/java/org/apache/cloudstack/storage/motion/StorageSystemDataMotionStrategy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2283,7 +2283,7 @@ private void handlePostMigration(boolean success, Map<VolumeInfo, VolumeInfo> sr
22832283
if (success) {
22842284
VolumeVO volumeVO = _volumeDao.findById(destVolumeInfo.getId());
22852285
volumeVO.setFormat(ImageFormat.QCOW2);
2286-
volumeVO.setPreviousId(srcVolumeInfo.getId());
2286+
volumeVO.setLastId(srcVolumeInfo.getId());
22872287

22882288
_volumeDao.update(volumeVO.getId(), volumeVO);
22892289

engine/storage/volume/src/main/java/org/apache/cloudstack/storage/volume/VolumeServiceImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1720,7 +1720,7 @@ protected VolumeVO duplicateVolumeOnAnotherStorage(Volume volume, StoragePool po
17201720
newVol.setPassphraseId(volume.getPassphraseId());
17211721
newVol.setEncryptFormat(volume.getEncryptFormat());
17221722
}
1723-
newVol.setPreviousId(volume.getId());
1723+
newVol.setLastId(volume.getId());
17241724
return volDao.persist(newVol);
17251725
}
17261726

0 commit comments

Comments
 (0)