mirror of https://github.com/apache/cloudstack.git
do not add disk cache mode from an empty string (#12248)
Co-authored-by: Daan Hoogland <dahn@apache.org>
This commit is contained in:
parent
63c8b5fc56
commit
fa3dee886e
|
|
@ -111,7 +111,9 @@ public class LibvirtDomainXMLParser {
|
|||
def.defNetworkBasedDisk(diskPath, host, port, authUserName, poolUuid, diskLabel,
|
||||
DiskDef.DiskBus.valueOf(bus.toUpperCase()),
|
||||
DiskDef.DiskProtocol.valueOf(protocol.toUpperCase()), fmt);
|
||||
def.setCacheMode(DiskDef.DiskCacheMode.valueOf(diskCacheMode.toUpperCase()));
|
||||
if (StringUtils.isNotBlank(diskCacheMode)) {
|
||||
def.setCacheMode(DiskDef.DiskCacheMode.valueOf(diskCacheMode.toUpperCase()));
|
||||
}
|
||||
} else {
|
||||
String diskFmtType = getAttrValue("driver", "type", disk);
|
||||
String diskCacheMode = getAttrValue("driver", "cache", disk);
|
||||
|
|
|
|||
Loading…
Reference in New Issue