[ovirt-devel] UI Plugin to Upload ISO Files

Nir Soffer nsoffer at redhat.com
Mon Dec 29 07:25:21 UTC 2014


----- Original Message -----
> From: "Tony James" <tony at anthonyjames.org>
> To: devel at ovirt.org
> Sent: Monday, December 29, 2014 3:30:49 AM
> Subject: [ovirt-devel] UI Plugin to Upload ISO Files
> 
> This message is in response to an earlier thread regarding a UI plugin
> to upload ISO files.  Like the original poster, Lucas, I began work on
> a UI plugin to allow uploading ISO files through a UI plugin.  After
> reading the previous thread I'm re-thinking the architecture.
> 
> It was suggested that the recommended approach to upload files to a
> storage domain is through the VDSM API [1].  I'm pretty familiar with
> the oVirt REST API but have been unable to find documentation
> regarding accessing the VDSM API.  Should the VDSM API be accessible
> by a UI plugin? If so, is there documentation available to do so?
> 
> [1] http://lists.ovirt.org/pipermail/devel/2014-December/009497.html

Basically you have to:
1. Use the vdsm xmlrpc/jsonrpc to create an image
2. Use the vdsm http api to upload the data to the image. This will create
   a task and return a task id.
3. Use the vdsm xmlrpc/jsonrpc api to check the task status, and clear
   the task when done

The xmlrpc/jsonrpc api is documented here:
http://gerrit.ovirt.org/gitweb?p=vdsm.git;a=blob;f=vdsm/rpc/vdsmapi-schema.json;h=1edcda86c8468b68c620eff4844b57ca30e44ea7;hb=HEAD

You can check the code for upload here:
http://gerrit.ovirt.org/gitweb?p=vdsm.git;a=blob;f=vdsm/rpc/BindingXMLRPC.py;h=759ed7845e63658a13c139684095bd56c03a29ac;hb=HEAD#l158

Nir



More information about the Devel mailing list