Change in ovirt-engine[ovirt-engine-3.5]: restapi: Add API to query block Storage Domains to import.

tnisan at redhat.com tnisan at redhat.com
Wed Jan 14 11:57:02 UTC 2015


Tal Nisan has submitted this change and it was merged.

Change subject: restapi: Add API to query block Storage Domains to import.
......................................................................


restapi: Add API to query block Storage Domains to import.

Adding an API called unregisteredstoragedomainsdiscover
hosts model.
The API should call a vdcQuery which will return all the unregistered
Storage Domains
The API should be called as follow:
POST
/api/hosts/052a880a-53e0-4fe3-9ed5-01f939d1df66/unregisteredstoragedomainsdiscover
HTTP/1.1
Accept: application/xml
Content-type: application/xml
<action>
    <iscsi>
        <address>iscsiHost</address>
    </iscsi>
    <iscsi_target>iqn.name1.120.01</iscsi_target>
    <iscsi_target>iqn.name2.120.02</iscsi_target>
    <iscsi_target>iqn.name3.120.03</iscsi_target>
</action>
The response which should returned as a list of Storage Domains, as
follow:
<action>
    <iscsi>
        <address>iscsiHost</address>
    </iscsi>
    <storage_domains>
        <storage_domain id="6ab65b16-0f03-4b93-85a7-5bc3b8d52be0">
            <name>scsi4</name>
            <type>data</type>
            <master>false</master>
            <storage>
                <type>iscsi</type>
                <volume_group
id="OLkKwa-VmEM-abW7-hPiv-BGrw-sQ2E-vTdAy1"/>
            </storage>
            <available>0</available>
            <used>0</used>
            <committed>0</committed>
            <storage_format>v3</storage_format>
        </storage_domain>
    <status>
        <state>complete</state>
    </status>
    <iscsi_target>iqn.name1.120.01</iscsi_target>
    <iscsi_target>iqn.name2.120.02</iscsi_target>
    <iscsi_target>iqn.name3.120.03</iscsi_target>
</action>

Change-Id: I54f4b6b9eb839ff5d6e9aabdc11af57e8c0b8da2
Bug-Url: https://bugzilla.redhat.com/1181681
Signed-off-by: Maor Lipchuk <mlipchuk at redhat.com>
---
M backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/HostResource.java
M backend/manager/modules/restapi/interface/definition/src/main/resources/api.xsd
M backend/manager/modules/restapi/interface/definition/src/main/resources/rsdl_metadata.yaml
M backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendHostResource.java
4 files changed, 72 insertions(+), 1 deletion(-)

Approvals:
  Juan Hernandez: Looks good to me, approved
  Maor Lipchuk: Verified



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

Gerrit-MessageType: merged
Gerrit-Change-Id: I54f4b6b9eb839ff5d6e9aabdc11af57e8c0b8da2
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.5
Gerrit-Owner: Maor Lipchuk <mlipchuk at redhat.com>
Gerrit-Reviewer: Juan Hernandez <juan.hernandez at redhat.com>
Gerrit-Reviewer: Maor Lipchuk <mlipchuk at redhat.com>
Gerrit-Reviewer: Tal Nisan <tnisan at redhat.com>
Gerrit-Reviewer: automation at ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server



More information about the Engine-commits mailing list