Bug 1346601

Summary: REST-API V3 | Cannot import network from external provider
Product: [oVirt] ovirt-engine Reporter: Meni Yakove <myakove>
Component: RestAPIAssignee: Marcin Mirecki <mmirecki>
Status: CLOSED WONTFIX QA Contact: Pavel Stehlik <pstehlik>
Severity: high Docs Contact:
Priority: high    
Version: 4.0.0CC: bugs, juan.hernandez, mmirecki, oourfali, ylavi
Target Milestone: ---Keywords: Automation
Target Release: ---Flags: sbonazzo: ovirt-4.0.z-
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-06-15 09:09:49 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Network RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
server and engine logs none

Description Meni Yakove 2016-06-15 05:27:20 UTC
Created attachment 1168157 [details]
server and engine logs

Description of problem:
Failed to import network from external network provider on V3 API.

Version-Release number of selected component (if applicable):
rhevm-4.0.0.4-0.1.el7ev.noarch

Steps to Reproduce:
1. Add external network provider to engine
2.POST to /ovirtengine/api/openstacknetworkproviders/<provider_id>/networks/<network_id>/import 

<action>
    <data_center id=<dc_id>>
    </data_center>
</action>



Actual results:
Failed

Expected results:
Network imported

Additional info:

2016-06-15 08:20:41,919 ERROR [org.jboss.resteasy.resteasy_jaxrs.i18n] (default task-6) RESTEASY002010: Failed to execute: javax.ws.rs.NotFoundException: RESTEASY003210: Could not find resou
rce for full path: https://network-ge-2.scl.lab.tlv.redhat.com/ovirt-engine/api/v3/openstacknetworkproviders/fc716aa9-f856-43ca-b82a-046ba7d3f0b2/networks/f1268b3f-d1d3-4505-84b2-b6c11d38f76
b/import
        at org.jboss.resteasy.core.registry.SegmentNode.match(SegmentNode.java:114) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.registry.RootNode.match(RootNode.java:43) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.LocatorRegistry.getResourceInvoker(LocatorRegistry.java:79) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invokeOnTargetObject(ResourceLocatorInvoker.java:129) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invoke(ResourceLocatorInvoker.java:107) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invokeOnTargetObject(ResourceLocatorInvoker.java:133) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invoke(ResourceLocatorInvoker.java:107) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invokeOnTargetObject(ResourceLocatorInvoker.java:133) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invoke(ResourceLocatorInvoker.java:107) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invokeOnTargetObject(ResourceLocatorInvoker.java:133) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.ResourceLocatorInvoker.invoke(ResourceLocatorInvoker.java:101) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:395) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:202) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:221) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:56) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:51) [resteasy-jaxrs.jar:3.0.16.Final-redhat-1]
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:790) [jboss-servlet-api_3.1_spec.jar:1.0.0.Final-redhat-1]

Comment 1 Juan Hernández 2016-06-15 09:09:41 UTC
This change is acceptable only if there is the commitment to backport it to the 3.6 branch.

In general the rule is that version 3 of the API is identical to what is currently available in the 3.6 branch. Doing this kind of changes deviates from those rules, and has several negative impacts for maintenance of the API:

1. The XML schema for version 3 of the API will be different in the two branches, thus it will be very difficult, if not impossible, to keep them in sync.

2. The RSDL schema for version 3 of the API will also be different. In the 3.6 branch it is automatically generated, and in the 4.0 branch it will need to be manually updated. Keeping them in sync will be very hard.

3. Version 3 of the Python and Java SDKs won't be able to use this new operation, as they are re-generated from the metadata contained in the 3.6 branch.

So, even if the change is technically correct, unless there is a commitment to backport this to the 3.6 branch I have to reject it.

Comment 2 Red Hat Bugzilla Rules Engine 2016-06-15 09:09:49 UTC
Development has indicated this request is declined. You may appeal this decision by reopening this request.