Dan Kenigsberg has submitted this change and it was merged.

Change subject: rest-api: Add the basic server infrastructure
......................................................................


rest-api: Add the basic server infrastructure

Add a new API binding for a REST API based on CherryPy and the Cheetah
templating framework.  This patch introduces the basic infrastructure for the
API as follows:

vdsm/clientIF.py
 * Initialize the REST API along with the XMLRPC binding.
 * The rest server is started in its own thread.  It will create more threads as
   needed.

vdsm/rest/BindingREST.py
 * REST API initialization

vdsm/rest/Controller.py
 * Main API logic controller
 * In this patch we introduce utilities and structure
 * Render the Root resource in the API

vdsm/rest/Dispatcher.py
 * A custom cherrypy URI dispatcher that handles URIs with nested identifiers:
    http://<server>:<port>/api/storagedomains/<sdUUID>/images/<imgUUID>

vdsm/rest/templates/api.xsd
vdsm/rest/templates/rsdl.xml
 * Define the rest API schema and valid URIs
 * This API is compatible with ovirt-engine-sdk and ovirt-engine-cli

vdsm/rest/templates/response.json.x
vdsm/rest/templates/response.xml.x
vdsm/rest/templates/root.json.x
vdsm/rest/templates/root.xml.x
 * Cheetah template files to render responses in json and xml format
 * The API can accept requests in either json or xml

API Implemented:
----------------
/api : The Root of the API
 * Provides vdsm version information
 * Lists the available sub-collections
 Actions: None

Change-Id: I8b914f7ad82fee8d9e7e3ce6847ffe4cda374a56
Signed-off-by: Adam Litke <a...@us.ibm.com>
---
M Makefile.am
M configure.ac
A tests/rest_override/__init__.py
M vdsm.spec.in
M vdsm/BindingXMLRPC.py
M vdsm/Makefile.am
M vdsm/clientIF.py
M vdsm/config.py.in
A vdsm/rest/BindingREST.py
A vdsm/rest/Controller.py
A vdsm/rest/Dispatcher.py
A vdsm/rest/Makefile.am
A vdsm/rest/__init__.py
A vdsm/rest/templates/Makefile.am
A vdsm/rest/templates/api.xsd
A vdsm/rest/templates/response.json.x
A vdsm/rest/templates/response.xml.x
A vdsm/rest/templates/root.json.x
A vdsm/rest/templates/root.xml.x
A vdsm/rest/templates/rsdl.xml
20 files changed, 1,126 insertions(+), 43 deletions(-)

Approvals:
  Dan Kenigsberg: Verified; Looks good to me, approved


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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8b914f7ad82fee8d9e7e3ce6847ffe4cda374a56
Gerrit-PatchSet: 8
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke <a...@us.ibm.com>
Gerrit-Reviewer: Adam Litke <a...@us.ibm.com>
Gerrit-Reviewer: Dan Kenigsberg <dan...@redhat.com>
Gerrit-Reviewer: Mark Wu <wu...@linux.vnet.ibm.com>
Gerrit-Reviewer: Royce Lv <lvro...@linux.vnet.ibm.com>
Gerrit-Reviewer: Saggi Mizrahi <smizr...@redhat.com>
Gerrit-Reviewer: ShaoHe Feng <shao...@linux.vnet.ibm.com>
Gerrit-Reviewer: Shu Ming <shum...@linux.vnet.ibm.com>
Gerrit-Reviewer: Wenchao Xia <xiaw...@linux.vnet.ibm.com>
_______________________________________________
vdsm-patches mailing list
vdsm-patches@lists.fedorahosted.org
https://fedorahosted.org/mailman/listinfo/vdsm-patches

Reply via email to