package org.zstack.header.vm;

import org.zstack.header.allocator.AllocationScene;
import org.zstack.header.message.NeedReplyMessage;

import java.util.List;

/**
 */
@SkipVmTracer(replyClass = MigrateVmReply.class)
public class MigrateVmMsg extends NeedReplyMessage implements VmInstanceMessage, MigrateVmMessage {
    private String vmInstanceUuid;
    private String strategy;
    private List<String> avoidHostUuids;
    private AllocationScene allocationScene;
    private String targetHostUuid;
    private boolean migrateFromDestination;

    @Override
    public AllocationScene getAllocationScene() {
        return allocationScene;
    }

    public void setAllocationScene(AllocationScene allocationScene) {
        this.allocationScene = allocationScene;
    }

    public List<String> getAvoidHostUuids() {
        return avoidHostUuids;
    }

    public void setAvoidHostUuids(List<String> avoidHostUuids) {
        this.avoidHostUuids = avoidHostUuids;
    }

    public String getVmInstanceUuid() {
        return vmInstanceUuid;
    }

    public void setVmInstanceUuid(String vmInstanceUuid) {
        this.vmInstanceUuid = vmInstanceUuid;
    }

    @Override
    public String getHostUuid() {
        return targetHostUuid;
    }

    @Override
    public boolean isMigrateFromDestination() {
        return migrateFromDestination;
    }

    public void setMigrateFromDestination(boolean migrateFromDestination) {
        this.migrateFromDestination = migrateFromDestination;
    }

    @Override
    public boolean isAllowUnknown() {
        return false;
    }

    @Override
    public String getStrategy() {
        return strategy;
    }

    public void setStrategy(String strategy) {
        this.strategy = strategy;
    }

    public String getTargetHostUuid() {
        return targetHostUuid;
    }

    public void setTargetHostUuid(String targetHostUuid) {
        this.targetHostUuid = targetHostUuid;
    }
}

@@ -537,16 +537,50 @@
 ination;
+%0A    private boolean allowUnknown;
 %0A%0A    @O
@@ -1524,32 +1524,137 @@
 ination;%0A    %7D%0A%0A
+    public void setAllowUnknown(boolean allowUnknown) %7B%0A        this.allowUnknown = allowUnknown;%0A    %7D%0A%0A
     @Override%0A  
@@ -1708,13 +1708,20 @@
 urn 
-f
 al
-se
+lowUnknown
 ;%0A  

Add allowUnknown in MigrateVmMsg