package org.zstack.header.other;

import org.zstack.header.message.APIEvent;
import org.zstack.header.message.APIMessage;

public interface APIAuditor {
    class Result {
        public String resourceUuid;
        public Class resourceType;

        public String getResourceUuid() {
            return resourceUuid;
        }

        public void setResourceUuid(String resourceUuid) {
            this.resourceUuid = resourceUuid;
        }

        public Class getResourceType() {
            return resourceType;
        }

        public void setResourceType(Class resourceType) {
            this.resourceType = resourceType;
        }

        public Result(String resourceUuid, Class resourceType) {
            this.resourceUuid = resourceUuid;
            this.resourceType = resourceType;
        }
    }

    Result audit(APIMessage msg, APIEvent rsp);
}

@@ -742,32 +742,132 @@
 = resourceUuid;%0A
+            if (this.resourceUuid == null) %7B%0A                this.resourceUuid = %22%22;%0A            %7D%0A%0A
             this

fix http://jira.zstack.io/browse/ZSTAC-12501