Skip to content

pre-commit upgrade codespell and fix spelling #10144

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/linters/codespell.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ aqcuire
aqcuired
aquire
aquiring
assertin
assiciate
assigne
assoication
Expand Down Expand Up @@ -65,6 +66,7 @@ bject
boardcast
bootstraper
bu
callin
cant
capabilites
capablity
Expand All @@ -73,6 +75,7 @@ carrefully
cavaet
chaing
checkd
checkin
childs
choosen
chould
Expand Down Expand Up @@ -165,6 +168,7 @@ disover
dissapper
dissassociated
divice
dockin
doesn'
doesnot
doesnt
Expand Down Expand Up @@ -195,6 +199,7 @@ excption
excute
execept
execption
exects
execut
executeable
exeeded
Expand Down Expand Up @@ -237,6 +242,7 @@ hanling
happend
hasing
hasnt
havin
hda
hostanme
hould
Expand Down Expand Up @@ -325,6 +331,7 @@ nin
nodel
nome
noone
notin
nowe
numbe
numer
Expand Down Expand Up @@ -417,6 +424,7 @@ returing
re-use
rever
rocessor
roperty
runing
runnign
sate
Expand Down Expand Up @@ -479,6 +487,7 @@ therefor
theres
theses
thi
thirdparty
thorugh
throught
ths
Expand Down
13 changes: 11 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,22 @@ repos:
args: [--markdown-linebreak-ext=md]
exclude: ^services/console-proxy/rdpconsole/src/test/doc/freerdp-debug-log\.txt$
- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
rev: v2.4.1
hooks:
- id: codespell
name: run codespell
description: Check spelling with codespell
args: [--ignore-words=.github/linters/codespell.txt]
exclude: ^ui/package\.json$|^ui/package-lock\.json$|^ui/public/js/less\.min\.js$|^ui/public/locales/.*[^n].*\.json$
exclude: |
(?x)^(
systemvm/agent/noVNC/app/locale/.*\.json|
systemvm/agent/noVNC/po/.*|
tools/eclipse/eclipse.epf|
ui/package\.json|
ui/package-lock\.json|
ui/public/js/less\.min\.js|
ui/public/locales/.*[^n].*\.json
)$
- repo: https://github.com/pycqa/flake8
rev: 7.0.0
hooks:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public class AgentProperties{

/**
* Local storage path.<br>
* This property allows multiple values to be entered in a single String. The differente values must be separated by commas.<br>
* This property allows multiple values to be entered in a single String. The different values must be separated by commas.<br>
* Data type: String.<br>
* Default value: <code>/var/lib/libvirt/images/</code>
*/
Expand All @@ -134,7 +134,7 @@ public class AgentProperties{

/**
* MANDATORY: The UUID for the local storage pool.<br>
* This property allows multiple values to be entered in a single String. The differente values must be separated by commas.<br>
* This property allows multiple values to be entered in a single String. The different values must be separated by commas.<br>
* Data type: String.<br>
* Default value: <code>null</code>
*/
Expand Down
2 changes: 1 addition & 1 deletion api/src/main/java/com/cloud/storage/Storage.java
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public static enum FileSystem {
public static enum TemplateType {
ROUTING, // Router template
SYSTEM, /* routing, system vm template */
BUILTIN, /* buildin template */
BUILTIN, /* builtin template */
PERHOST, /* every host has this template, don't need to install it in secondary storage */
USER, /* User supplied template/iso */
VNF, /* VNFs (virtual network functions) template */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
import org.apache.cloudstack.storage.command.AttachCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectCommand;
import org.apache.cloudstack.storage.command.DeleteCommand;
Expand Down Expand Up @@ -82,7 +82,7 @@ public interface StorageProcessor {

Answer copyVolumeFromPrimaryToPrimary(CopyCommand cmd);

public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd);
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd);

public Answer syncVolumePath(SyncVolumePathCommand cmd);
}
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
import org.apache.cloudstack.storage.command.AttachCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
import org.apache.cloudstack.storage.command.CreateObjectCommand;
Expand Down Expand Up @@ -79,8 +79,8 @@
return processor.resignature((ResignatureCommand) command);
} else if (command instanceof DirectDownloadCommand) {
return processor.handleDownloadTemplateToPrimaryStorage((DirectDownloadCommand) command);
} else if (command instanceof CheckDataStoreStoragePolicyComplainceCommand) {
return processor.checkDataStoreStoragePolicyCompliance((CheckDataStoreStoragePolicyComplainceCommand) command);
} else if (command instanceof CheckDataStoreStoragePolicyComplianceCommand) {
return processor.checkDataStoreStoragePolicyCompliance((CheckDataStoreStoragePolicyComplianceCommand) command);

Check warning on line 83 in core/src/main/java/com/cloud/storage/resource/StorageSubsystemCommandHandlerBase.java

View check run for this annotation

Codecov / codecov/patch

core/src/main/java/com/cloud/storage/resource/StorageSubsystemCommandHandlerBase.java#L83

Added line #L83 was not covered by tests
} else if (command instanceof SyncVolumePathCommand) {
return processor.syncVolumePath((SyncVolumePathCommand) command);
} else if (command instanceof QuerySnapshotZoneCopyCommand) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@

import com.cloud.agent.api.to.StorageFilerTO;

public class CheckDataStoreStoragePolicyComplainceCommand extends StorageSubSystemCommand {
public class CheckDataStoreStoragePolicyComplianceCommand extends StorageSubSystemCommand {

String storagePolicyId;
private StorageFilerTO storagePool;

public CheckDataStoreStoragePolicyComplainceCommand(String storagePolicyId, StorageFilerTO storagePool) {
public CheckDataStoreStoragePolicyComplianceCommand(String storagePolicyId, StorageFilerTO storagePool) {
super();

this.storagePolicyId = storagePolicyId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ public interface StorageManager extends StorageService {

/**
* should we execute in sequence not involving any storages?
* @return tru if commands should execute in sequence
* @return true if commands should execute in sequence
*/
static boolean shouldExecuteInSequenceOnVmware() {
return shouldExecuteInSequenceOnVmware(null, null);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public interface VMSnapshotManager extends VMSnapshotService, Manager {
boolean deleteAllVMSnapshots(long id, VMSnapshot.Type type);

/**
* Sync VM snapshot state when VM snapshot in reverting or snapshoting or expunging state
* Sync VM snapshot state when VM snapshot in reverting or snapshotting or expunging state
* Used for fullsync after agent connects
*
* @param vm, the VM in question
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@
return false;
}
} catch (StorageUnavailableException e) {
logger.warn(String.format("Could not verify storage policy complaince against storage pool %s due to exception %s", pool.getUuid(), e.getMessage()));
logger.warn(String.format("Could not verify storage policy compliance against storage pool %s due to exception %s", pool.getUuid(), e.getMessage()));

Check warning on line 359 in engine/storage/src/main/java/org/apache/cloudstack/storage/allocator/AbstractStoragePoolAllocator.java

View check run for this annotation

Codecov / codecov/patch

engine/storage/src/main/java/org/apache/cloudstack/storage/allocator/AbstractStoragePoolAllocator.java#L359

Added line #L359 was not covered by tests
return false;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1267,8 +1267,8 @@ public bool IsVMQOffloadUsageNull {

[Browsable(true)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
[Description("The current VMQ offloading usage on this port. The usage is the amount of VMQ res" +
"ources in use on the port.")]
[Description("The current VMQ offloading usage on this port. The usage is the amount of VMQ " +
"resources in use on the port.")]
[TypeConverter(typeof(WMIValueTypeConverter))]
public uint VMQOffloadUsage {
get {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -618,10 +618,9 @@ public bool IsIsBoundNull {

[Browsable(true)]
[DesignerSerializationVisibility(DesignerSerializationVisibility.Hidden)]
[Description("If this property is true, then this Ethernet port can be connected to the switche" +
"s and thus can provide connectivity to virtual machine. If this property is fals" +
"e, then this Ethernet is not being used by the virtual machine networking archit" +
"ecture.")]
[Description("If this property is true, then this Ethernet port can be connected to the switches" +
" and thus can provide connectivity to virtual machine. If this property is false" +
", then this Ethernet is not being used by the virtual machine networking architecture.")]
[TypeConverter(typeof(WMIValueTypeConverter))]
public bool IsBound {
get {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
import org.apache.cloudstack.engine.subsystem.api.storage.SnapshotInfo;
import org.apache.cloudstack.storage.command.AttachAnswer;
import org.apache.cloudstack.storage.command.AttachCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.CopyCmdAnswer;
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
Expand Down Expand Up @@ -2629,8 +2629,8 @@
}

@Override
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd) {
logger.info("'CheckDataStoreStoragePolicyComplainceCommand' not currently applicable for KVMStorageProcessor");
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd) {
logger.info("'CheckDataStoreStoragePolicyComplianceCommand' not currently applicable for KVMStorageProcessor");

Check warning on line 2633 in plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java#L2632-L2633

Added lines #L2632 - L2633 were not covered by tests
return new Answer(cmd,false,"Not currently applicable for KVMStorageProcessor");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
import org.apache.cloudstack.storage.command.AttachAnswer;
import org.apache.cloudstack.storage.command.AttachCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.CopyCmdAnswer;
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
Expand Down Expand Up @@ -830,8 +830,8 @@
}

@Override
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd) {
logger.info("'CheckDataStoreStoragePolicyComplainceCommand' not applicable used for Ovm3StorageProcessor");
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd) {
logger.info("'CheckDataStoreStoragePolicyComplianceCommand' not applicable used for Ovm3StorageProcessor");

Check warning on line 834 in plugins/hypervisors/ovm3/src/main/java/com/cloud/hypervisor/ovm3/resources/Ovm3StorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/ovm3/src/main/java/com/cloud/hypervisor/ovm3/resources/Ovm3StorageProcessor.java#L834

Added line #L834 was not covered by tests
return new Answer(cmd,false,"Not applicable used for Ovm3StorageProcessor");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
import org.apache.cloudstack.storage.command.CreateObjectCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.DeleteCommand;
import org.apache.cloudstack.storage.command.DettachAnswer;
import org.apache.cloudstack.storage.command.DettachCommand;
Expand Down Expand Up @@ -274,7 +274,7 @@ public Answer copyVolumeFromPrimaryToPrimary(CopyCommand cmd) {
}

@Override
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd) {
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd) {
return new Answer(cmd, true, null);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
import org.apache.cloudstack.framework.config.dao.ConfigurationDao;
import org.apache.cloudstack.framework.jobs.impl.AsyncJobManagerImpl;
import org.apache.cloudstack.management.ManagementServerHost;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao;
import org.apache.cloudstack.storage.datastore.db.StoragePoolVO;
import org.apache.cloudstack.utils.identity.ManagementServerNode;
Expand Down Expand Up @@ -1572,7 +1572,7 @@
continue;
}
Collections.shuffle(hostIds);
CheckDataStoreStoragePolicyComplainceCommand command = new CheckDataStoreStoragePolicyComplainceCommand(storagePolicy.getPolicyId(), storageFilerTO);
CheckDataStoreStoragePolicyComplianceCommand command = new CheckDataStoreStoragePolicyComplianceCommand(storagePolicy.getPolicyId(), storageFilerTO);

Check warning on line 1575 in plugins/hypervisors/vmware/src/main/java/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java#L1575

Added line #L1575 was not covered by tests
long targetHostId = hypervisorGuruManager.getGuruProcessedCommandTargetHost(hostIds.get(0), command);
try {
Answer answer = _agentMgr.send(targetHostId, command);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4522,7 +4522,7 @@
vmMo.mountToolsInstaller();
logger.debug(String.format("Successfully re-mounted vmware tools installer for :[%s].", cmd.getVmName()));
} catch (Exception e) {
logger.error(String.format("Unabled to re-mount vmware tools installer for: [%s].", cmd.getVmName()), e);
logger.error(String.format("Unable to re-mount vmware tools installer for: [%s].", cmd.getVmName()), e);

Check warning on line 4525 in plugins/hypervisors/vmware/src/main/java/com/cloud/hypervisor/vmware/resource/VmwareResource.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/hypervisor/vmware/resource/VmwareResource.java#L4525

Added line #L4525 was not covered by tests
}
}
}
Expand Down Expand Up @@ -6977,7 +6977,7 @@
if (s_serviceContext.get() != null) {
context = s_serviceContext.get();
String poolKey = VmwareContextPool.composePoolKey(_vCenterAddress, _username);
// Before re-using the thread local context, ensure it corresponds to the right vCenter API session and that it is valid to make calls.
// Before reusing the thread local context, ensure it corresponds to the right vCenter API session and that it is valid to make calls.
if (context.getPoolKey().equals(poolKey)) {
if (context.validate()) {
if (logger.isTraceEnabled()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
import org.apache.cloudstack.agent.directdownload.DirectDownloadCommand;
import org.apache.cloudstack.storage.command.AttachAnswer;
import org.apache.cloudstack.storage.command.AttachCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplainceCommand;
import org.apache.cloudstack.storage.command.CheckDataStoreStoragePolicyComplianceCommand;
import org.apache.cloudstack.storage.command.CopyCmdAnswer;
import org.apache.cloudstack.storage.command.CopyCommand;
import org.apache.cloudstack.storage.command.CreateObjectAnswer;
Expand Down Expand Up @@ -997,11 +997,11 @@
long wait, String nfsVersion) throws Exception {
String volumeFolder;
String volumeName;
String sufix = ".ova";
String suffix = ".ova";

Check warning on line 1000 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L1000

Added line #L1000 was not covered by tests
int index = srcVolumePath.lastIndexOf(File.separator);
if (srcVolumePath.endsWith(sufix)) {
if (srcVolumePath.endsWith(suffix)) {
volumeFolder = srcVolumePath.substring(0, index);
volumeName = srcVolumePath.substring(index + 1).replace(sufix, "");
volumeName = srcVolumePath.substring(index + 1).replace(suffix, "");

Check warning on line 1004 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L1004

Added line #L1004 was not covered by tests
} else {
volumeFolder = srcVolumePath;
volumeName = srcVolumePath.substring(index + 1);
Expand Down Expand Up @@ -3775,7 +3775,7 @@
}

@Override
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplainceCommand cmd) {
public Answer checkDataStoreStoragePolicyCompliance(CheckDataStoreStoragePolicyComplianceCommand cmd) {

Check warning on line 3778 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3778

Added line #L3778 was not covered by tests
String primaryStorageNameLabel = cmd.getStoragePool().getUuid();
String storagePolicyId = cmd.getStoragePolicyId();
VmwareContext context = hostService.getServiceContext(cmd);
Expand All @@ -3789,16 +3789,16 @@
}

DatastoreMO primaryDsMo = new DatastoreMO(hyperHost.getContext(), morPrimaryDs);
boolean isDatastoreStoragePolicyComplaint = primaryDsMo.isDatastoreStoragePolicyComplaint(storagePolicyId);
boolean isDatastoreStoragePolicyCompliant = primaryDsMo.isDatastoreStoragePolicyCompliant(storagePolicyId);

Check warning on line 3792 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3792

Added line #L3792 was not covered by tests

String failedMessage = String.format("DataStore %s is not complaince with storage policy id %s", primaryStorageNameLabel, storagePolicyId);
if (!isDatastoreStoragePolicyComplaint)
return new Answer(cmd, isDatastoreStoragePolicyComplaint, failedMessage);
String failedMessage = String.format("DataStore %s is not compliant with storage policy id %s", primaryStorageNameLabel, storagePolicyId);

Check warning on line 3794 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3794

Added line #L3794 was not covered by tests
if (!isDatastoreStoragePolicyCompliant)
return new Answer(cmd, isDatastoreStoragePolicyCompliant, failedMessage);

Check warning on line 3796 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3796

Added line #L3796 was not covered by tests
else
return new Answer(cmd, isDatastoreStoragePolicyComplaint, null);
return new Answer(cmd, isDatastoreStoragePolicyCompliant, null);

Check warning on line 3798 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3798

Added line #L3798 was not covered by tests
} catch (Throwable e) {
hostService.createLogMessageException(e, cmd);
String details = String.format("Exception while checking if datastore [%s] is storage policy [%s] complaince due to: [%s]", primaryStorageNameLabel, storagePolicyId, VmwareHelper.getExceptionMessage(e));
String details = String.format("Exception while checking if datastore [%s] is storage policy [%s] compliant due to: [%s]", primaryStorageNameLabel, storagePolicyId, VmwareHelper.getExceptionMessage(e));

Check warning on line 3801 in plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java

View check run for this annotation

Codecov / codecov/patch

plugins/hypervisors/vmware/src/main/java/com/cloud/storage/resource/VmwareStorageProcessor.java#L3801

Added line #L3801 was not covered by tests
return new Answer(cmd, false, details);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3770,7 +3770,7 @@ protected List<SR> getAllLocalSrForType(Connection conn, SRType srType) throws X
Host host = pbd.getHost(conn);
if (!isRefNull(host) && StringUtils.equals(host.getUuid(conn), _host.getUuid())) {
if (!pbd.getCurrentlyAttached(conn)) {
logger.debug(String.format("PBD [%s] of local SR [%s] was unplugged, pluggin it now", pbd.getUuid(conn), srRec.uuid));
logger.debug(String.format("PBD [%s] of local SR [%s] was unplugged, plugging it in now", pbd.getUuid(conn), srRec.uuid));
pbd.plug(conn);
}
logger.debug("Scanning local SR: " + srRec.uuid);
Expand Down
Loading
Loading