Juan Hernandez has posted comments on this change.

Change subject: restapi: clone vm
......................................................................


Patch Set 3:

(3 comments)

http://gerrit.ovirt.org/#/c/26526/3/backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/VmResource.java
File 
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/VmResource.java:

Line 33: 
Line 34: @Produces({ApiMediaType.APPLICATION_XML, 
ApiMediaType.APPLICATION_JSON, ApiMediaType.APPLICATION_X_YAML})
Line 35: public interface VmResource extends UpdatableResource<VM>, 
AsynchronouslyCreatedResource, MeasurableResource {
Line 36: 
Line 37:     @Path("{action: 
(start|stop|shutdown|reboot|suspend|detach|migrate|export|move|ticket|cancelmigration|preview_snapshot|commit_snapshot|undo_snapshot|clone_vm)}/{oid}")
It should be "clone" here ^.
Line 38:     public ActionResource 
getActionSubresource(@PathParam("action")String action, @PathParam("oid")String 
oid);
Line 39: 
Line 40:     @POST
Line 41:     @Formatted


http://gerrit.ovirt.org/#/c/26526/3/backend/manager/modules/restapi/interface/definition/src/main/resources/api.xsd
File 
backend/manager/modules/restapi/interface/definition/src/main/resources/api.xsd:

Line 203:       <xs:element name="job" type="Job" minOccurs="0"/>
Line 204:       <!-- indicates whether to import the image as template or not 
-->
Line 205:       <xs:element name="import_as_template" type="xs:boolean" 
minOccurs="0" maxOccurs="1"/>
Line 206:       <!--for clone vm-->
Line 207:       <xs:element name="clone_configuration" type="VM" minOccurs="0" 
maxOccurs="1"/>
Looking at this more carefully I see that we already have a "vm" element of 
type VM (used for the start VM operation). Can we reuse it instead of intruduce 
the "clone_configuration" element?
Line 208:     </xs:sequence>
Line 209:   </xs:group>
Line 210: 
Line 211:   <xs:group name="ActionResponseGroup">


http://gerrit.ovirt.org/#/c/26526/3/backend/manager/modules/restapi/interface/definition/src/main/resources/rsdl_metadata.yaml
File 
backend/manager/modules/restapi/interface/definition/src/main/resources/rsdl_metadata.yaml:

Line 406:   request:
Line 407:     body:
Line 408:       parameterType: Action
Line 409:       signatures:
Line 410:       - mandatoryArguments: {action.clone_configuration.name}
If we reuse the "vm" element this should be "action.vm.name".
Line 411:     urlparams: {}
Line 412:     headers:
Line 413:       Content-Type: {value: application/xml|json, required: true}
Line 414:       Correlation-Id: {value: 'any string', required: false}


-- 
To view, visit http://gerrit.ovirt.org/26526
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I18cb01dc83f0a57a7a572fa0da0c7e3397c43707
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Tomas Jelinek <tjeli...@redhat.com>
Gerrit-Reviewer: Juan Hernandez <juan.hernan...@redhat.com>
Gerrit-Reviewer: Tomas Jelinek <tjeli...@redhat.com>
Gerrit-Reviewer: automat...@ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to