mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
api,server: encryptformat in volume response (#9106)
Fixes #9014 * api,server: encryptformat in volume response * Apply suggestions from code review * remove passphrase db change
This commit is contained in:
parent
3321971adc
commit
fcca3e8f39
@ -290,13 +290,17 @@ public class VolumeResponse extends BaseResponseWithTagInformation implements Co
|
|||||||
private String externalUuid;
|
private String externalUuid;
|
||||||
|
|
||||||
@SerializedName(ApiConstants.VOLUME_CHECK_RESULT)
|
@SerializedName(ApiConstants.VOLUME_CHECK_RESULT)
|
||||||
@Param(description = "details for the volume check result, they may vary for different hypervisors, since = 4.19.1")
|
@Param(description = "details for the volume check result, they may vary for different hypervisors", since = "4.19.1")
|
||||||
private Map<String, String> volumeCheckResult;
|
private Map<String, String> volumeCheckResult;
|
||||||
|
|
||||||
@SerializedName(ApiConstants.VOLUME_REPAIR_RESULT)
|
@SerializedName(ApiConstants.VOLUME_REPAIR_RESULT)
|
||||||
@Param(description = "details for the volume repair result, they may vary for different hypervisors, since = 4.19.1")
|
@Param(description = "details for the volume repair result, they may vary for different hypervisors", since = "4.19.1")
|
||||||
private Map<String, String> volumeRepairResult;
|
private Map<String, String> volumeRepairResult;
|
||||||
|
|
||||||
|
@SerializedName(ApiConstants.ENCRYPT_FORMAT)
|
||||||
|
@Param(description = "the encrypt format of the volume", since = "4.19.1")
|
||||||
|
private String encryptFormat;
|
||||||
|
|
||||||
public String getPath() {
|
public String getPath() {
|
||||||
return path;
|
return path;
|
||||||
}
|
}
|
||||||
@ -842,4 +846,8 @@ public class VolumeResponse extends BaseResponseWithTagInformation implements Co
|
|||||||
public void setVolumeRepairResult(Map<String, String> volumeRepairResult) {
|
public void setVolumeRepairResult(Map<String, String> volumeRepairResult) {
|
||||||
this.volumeRepairResult = volumeRepairResult;
|
this.volumeRepairResult = volumeRepairResult;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void setEncryptFormat(String encryptFormat) {
|
||||||
|
this.encryptFormat = encryptFormat;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -39,6 +39,7 @@ SELECT
|
|||||||
`volumes`.`path` AS `path`,
|
`volumes`.`path` AS `path`,
|
||||||
`volumes`.`chain_info` AS `chain_info`,
|
`volumes`.`chain_info` AS `chain_info`,
|
||||||
`volumes`.`external_uuid` AS `external_uuid`,
|
`volumes`.`external_uuid` AS `external_uuid`,
|
||||||
|
`volumes`.`encrypt_format` AS `encrypt_format`,
|
||||||
`account`.`id` AS `account_id`,
|
`account`.`id` AS `account_id`,
|
||||||
`account`.`uuid` AS `account_uuid`,
|
`account`.`uuid` AS `account_uuid`,
|
||||||
`account`.`account_name` AS `account_name`,
|
`account`.`account_name` AS `account_name`,
|
||||||
|
|||||||
@ -180,6 +180,7 @@ public class VolumeJoinDaoImpl extends GenericDaoBaseWithTagInformation<VolumeJo
|
|||||||
|
|
||||||
if (view == ResponseView.Full) {
|
if (view == ResponseView.Full) {
|
||||||
volResponse.setPath(volume.getPath());
|
volResponse.setPath(volume.getPath());
|
||||||
|
volResponse.setEncryptFormat(volume.getEncryptFormat());
|
||||||
}
|
}
|
||||||
|
|
||||||
// populate owner.
|
// populate owner.
|
||||||
|
|||||||
@ -275,6 +275,9 @@ public class VolumeJoinVO extends BaseViewWithTagInformationVO implements Contro
|
|||||||
@Column(name = "external_uuid")
|
@Column(name = "external_uuid")
|
||||||
private String externalUuid = null;
|
private String externalUuid = null;
|
||||||
|
|
||||||
|
@Column(name = "encrypt_format")
|
||||||
|
private String encryptFormat;
|
||||||
|
|
||||||
public VolumeJoinVO() {
|
public VolumeJoinVO() {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -610,6 +613,10 @@ public class VolumeJoinVO extends BaseViewWithTagInformationVO implements Contro
|
|||||||
this.externalUuid = externalUuid;
|
this.externalUuid = externalUuid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getEncryptFormat() {
|
||||||
|
return encryptFormat;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Class<?> getEntityType() {
|
public Class<?> getEntityType() {
|
||||||
return Volume.class;
|
return Volume.class;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user