Juan Hernandez has submitted this change and it was merged.
Change subject: restapi: OpenStack network provider
......................................................................
restapi: OpenStack network provider
This patch adds the resources for the OpenStack neetwork providers. The
representation of the resource will look like this:
GET /openstackneetworkproviders
<openstack_network_providers>
<openstack_network_provider
id="{provider:id}">...</openstack_network_provider>
...
</openstack_network_providers>
GET /openstacknetworkproviders/{provider:id}
<openstack_network_provider id="{provider:id}">
<name>myprovider</name>
<description>My provider</description>
<url>http://neutron.example.com</url>
<username>myuser</username>
<password>mypass</password>
<tenant_name>mytenant</tenant_name>
<plugin_type>open_vswitch<plugin_type>
<agent_configuration>
<network_mappings>...</network_mappings>
<broker_type>qpid|rabbit_mq<broker_type>
<address>...</address>
<port>...</port>
<username>...</username>
<password>...</password>
</agent_configuration>
<properties>
<property>
<name>prop1</name>
<value>value1</myvalue>
</property>
<property>
<name>prop2</name>
<value>value2</myvalue>
</property>
</properties>
</openstack_network_provider>
The providers collection will support listing, getting, adding and
removing providers, with the usual methods.
The provider resource will support getting, deleting and updating the
provider, with the usual methods. In addition it will support the
"testconnectivity" and "importcertificates" operations. The first
used
to check the connectivity with the external provider:
POST /openstacknetworkproviders/{provider:id}/testconnectivity
<action/>
The second is used to import the chain of certificates of the external
provider:
POST /openstacknetworkproviders/{provider:id}/importcertificates
<action/>
The provider resource includes sub-collections for certificates and
networks. For certificates it will look like this:
GET /openstacknetworkproviders/{provider:id}/certificates
<certificates>
<certificate id="{host:id}">...</certificate>
...
</certificates>
GET /openstacknetworkproviders/{provider:id}/certificates/{certificate:id}
<certificate id="{certificate:id}">
<subject>CN=neutron.example.com</subject>
<content>...</content>
</certificate>
For networks:
GET /openstacknetworkproviders/{provider:id}/networks
<openstack_networks>
<openstack_network id="{network:id}">...</openstack_network>
...
</openstack_networks>
GET /openstacknetworkproviders/{provider:id}/networks/{network:id}
<openstack_network id="{networkd:id}">
<name>mynetwork</name>
</openstack_network>
The network resource will in turn include a sub-collection for
sub-networks:
GET /openstacknetworproviders/{provider:id}/networks/{network:id}/subnets
<openstack_subnets>
<openstack_subnet id="{subnet:id}">...<openstack_subnet>
...
</openstack_subnets>
GET /openstacknetworproviders/{provider:id}/networks/{network:id}/subnets/{subnet:id}
<openstack_subnet id="{subnet:id}">
<cidr>...</cidr>
<ip_version>v4|v6<ip_version>
<gateway>192.168.122.1</gateway>
<dns_servers>
<dns_server>192.168.122.1</dns_server>
<dns_server>192.168.122.2</dns_server>
...
</dns_servers>
</openstack_subnet>
Change-Id: I0ff73ad3dfc3c220716cd6ec8ca635f5c3bb348d
Bug-Url:
https://bugzilla.redhat.com/1132259
Signed-off-by: Juan Hernandez <juan.hernandez(a)redhat.com>
---
M
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/network/AddSubnetToProviderCommand.java
A
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/provider/network/GetExternalSubnetsOnProviderByExternalNetworkQuery.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/action/AddExternalSubnetParameters.java
A
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/queries/GetExternalSubnetsOnProviderByExternalNetworkQueryParameters.java
M
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/queries/VdcQueryType.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/model/MessageBrokerType.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/model/NetworkPluginType.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackNetworkProviderResource.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackNetworkProvidersResource.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackNetworkResource.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackNetworksResource.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackSubnetResource.java
A
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/resource/openstack/OpenStackSubnetsResource.java
M
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/utils/ApiRootLinksCreator.java
M
backend/manager/modules/restapi/interface/definition/src/main/java/org/ovirt/engine/api/utils/LinkHelper.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/BackendApplication.java
M
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/BackendCapabilitiesResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkProviderResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkProvidersResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworksResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackSubnetResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackSubnetsResource.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/validation/OpenStackNetworkProviderValidator.java
A
backend/manager/modules/restapi/jaxrs/src/main/java/org/ovirt/engine/api/restapi/resource/validation/openstack/OpenStackSubnetValidator.java
M
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/BackendApiResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkProviderResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkProvidersResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworkResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackNetworksResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackSubnetResourceTest.java
A
backend/manager/modules/restapi/jaxrs/src/test/java/org/ovirt/engine/api/restapi/resource/openstack/BackendOpenStackSubnetsResourceTest.java
A
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/IpVersionMapper.java
A
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackNetworkMapper.java
A
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackNetworkProviderMapper.java
A
backend/manager/modules/restapi/types/src/main/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackSubnetMapper.java
A
backend/manager/modules/restapi/types/src/test/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackNetworkMapperTest.java
A
backend/manager/modules/restapi/types/src/test/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackNetworkProviderMapperTest.java
A
backend/manager/modules/restapi/types/src/test/java/org/ovirt/engine/api/restapi/types/openstack/OpenStackSubnetMapperTest.java
M
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/datacenters/NewNetworkModel.java
M
frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/providers/NewExternalSubnetModel.java
43 files changed, 2,550 insertions(+), 37 deletions(-)
Approvals:
Juan Hernandez: Verified; Looks good to me, approved
--
To view, visit
http://gerrit.ovirt.org/33087
To unsubscribe, visit
http://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I0ff73ad3dfc3c220716cd6ec8ca635f5c3bb348d
Gerrit-PatchSet: 22
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Juan Hernandez <juan.hernandez(a)redhat.com>
Gerrit-Reviewer: Juan Hernandez <juan.hernandez(a)redhat.com>
Gerrit-Reviewer: Mike Kolesnik <mkolesni(a)redhat.com>
Gerrit-Reviewer: automation(a)ovirt.org
Gerrit-Reviewer: oVirt Jenkins CI Server