add note on vmwarweguru->getCommandHostDelegation

Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/211524f3
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/211524f3
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/211524f3

Branch: refs/heads/master
Commit: 211524f3bcd304852b57f1b248163b26527d4fd4
Parents: c42f51d
Author: Edison Su <[email protected]>
Authored: Tue Jul 30 11:37:05 2013 -0700
Committer: Edison Su <[email protected]>
Committed: Tue Jul 30 16:17:06 2013 -0700

----------------------------------------------------------------------
 .../vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java           | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/211524f3/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java
----------------------------------------------------------------------
diff --git 
a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java 
b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java
index 95152fc..d699a1e 100644
--- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java
+++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/guru/VMwareGuru.java
@@ -300,6 +300,8 @@ public class VMwareGuru extends HypervisorGuruBase 
implements HypervisorGuru {
     public Pair<Boolean, Long> getCommandHostDelegation(long hostId, Command 
cmd) {
         boolean needDelegation = false;
 
+        //NOTE: the hostid can be a hypervisor host, or a ssvm agent. For 
copycommand, if it's for volume upload, the hypervisor
+        //type is empty, so we need to check the format of volume at first.
         if (cmd instanceof CopyCommand) {
             CopyCommand cpyCommand = (CopyCommand)cmd;
             DataTO srcData = cpyCommand.getSrcTO();

Reply via email to