Hi, Subhash,

For 1)

Look at step 15.a:

“note: you will need to perform a GET each time and update the resource version 
of the cloud-region in the XML payload for the clear, and do the GET again and 
update the resource-version QueryParam to perform
the delete”

You need to update the payload of the PUT with the current resource-version 
from the object that was returned by the GET.

So, GET the cloud-region, copy the resource-version attribute, and paste it 
into the payload, then PUT the object again (you have to clear the children 
before you can DELETE it).

For 2)

In the example you show, you would use the resource-version 1503568360066 in 
the request.

?resource-version=1503568360066 appended to the URL.

Thanks,
jimmy

From: [email protected] 
[mailto:[email protected]] On Behalf Of Subhash Kumar Singh
Sent: Thursday, August 24, 2017 10:23 AM
To: [email protected]
Subject: [onap-discuss] Query on schema change tutorial in A&AI

Hello AAI Team,

We are trying to follow tutorial page for schema change in A&AI, but we are 
facing issues.
We would like to ask following questions:


1.       Not able to delete created cloud-region (step 15 in tutorial page 
[1]). Could you please share postman query to delete it.



2.       Similar to previous case, we tried to delete created “New Widget” but 
we are seeing exception “resource version not passed” but I can’t find any 
resource version in new-widget schema.



Response from delete query: DELETE
https://192.168.17.34:8447/aai/v11/network/new-widgets/new-widget/example-new-widget-name-val-46235<https://urldefense.proofpoint.com/v2/url?u=https-3A__192.168.17.34-3A8447_aai_v11_network_new-2Dwidgets_new-2Dwidget_example-2Dnew-2Dwidget-2Dname-2Dval-2D46235&d=DwMFbw&c=LFYZ-o9_HUMeMTSQicvjIg&r=Oej6QUk5p2KdqNEWySpOHA&m=NvK46u9vIKqEoXeNxluOHgU4upLT2GpThYdKkLUAm5A&s=SGUgbuCTwT7hwpA5mJGKhHbUDsawrMMgIxB2Cygnmjg&e=>


<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Fault>
    <requestError>
        <serviceException>
            <messageId>SVC3000</messageId>
            <text>Invalid input performing %1 on %2 (msg=%3) (ec=%4)</text>
            <variables>
                <variable>DELETE</variable>
                
<variable>network/new-widgets/new-widget/example-new-widget-name-val-46235</variable>
                <variable>Precondition Required:resource-version not passed for 
delete of new-widget</variable>
                <variable>ERR.5.4.6130</variable>
            </variables>
        </serviceException>
    </requestError>
</Fault>


Response from get query: GET
 
https://192.168.17.34:8447/aai/v11/network/new-widgets/new-widget/example-new-widget-name-val-46235<https://urldefense.proofpoint.com/v2/url?u=https-3A__192.168.17.34-3A8447_aai_v11_network_new-2Dwidgets_new-2Dwidget_example-2Dnew-2Dwidget-2Dname-2Dval-2D46235&d=DwMFbw&c=LFYZ-o9_HUMeMTSQicvjIg&r=Oej6QUk5p2KdqNEWySpOHA&m=NvK46u9vIKqEoXeNxluOHgU4upLT2GpThYdKkLUAm5A&s=SGUgbuCTwT7hwpA5mJGKhHbUDsawrMMgIxB2Cygnmjg&e=>
<?xml version="1.0" encoding="UTF-8"?>
<new-widget 
xmlns="http://org.openecomp.aai.inventory/v11<https://urldefense.proofpoint.com/v2/url?u=http-3A__org.openecomp.aai.inventory_v11&d=DwMFbw&c=LFYZ-o9_HUMeMTSQicvjIg&r=Oej6QUk5p2KdqNEWySpOHA&m=NvK46u9vIKqEoXeNxluOHgU4upLT2GpThYdKkLUAm5A&s=xuPVKuj5NJaiTR6flWNSf3fiQsAD09EkUjkyUWYufG8&e=>">
    <new-widget-name>example-new-widget-name-val-46235</new-widget-name>
    <new-widget-type>example-new-widget-type-val-5238</new-widget-type>
    <resource-version>1503568360066</resource-version>
    
<model-invariant-id>example-model-invariant-id-val-10431</model-invariant-id>
    <model-version-id>example-model-version-id-val-35005</model-version-id>
    <new-widget-id>example-new-widget-id-val-2651</new-widget-id>
</new-widget>

Kindly help us to understand the issues.

[1] 
https://wiki.onap.org/pages/viewpage.action?pageId=10783023<https://urldefense.proofpoint.com/v2/url?u=https-3A__wiki.onap.org_pages_viewpage.action-3FpageId-3D10783023&d=DwMFbw&c=LFYZ-o9_HUMeMTSQicvjIg&r=Oej6QUk5p2KdqNEWySpOHA&m=NvK46u9vIKqEoXeNxluOHgU4upLT2GpThYdKkLUAm5A&s=1XdmW6rMQObCfoJRIXRzCXujF8sxFHw_gIHXq9C5pCc&e=>

--
Regards,
Subhash Kumar Singh

***************************************************************************************
本邮件及其附件含有华为公司的保密信息,仅限于发送给上面地址中列出的个人或群组。禁止任何其他人以任何形式使用(包括但不限于全部或部分地泄露、复制、或散发)本邮件中的信息。如果您错收了本邮件,请您立即电话或邮件通知发件人并删除本邮件!**************************************************************************************

***************************************************************************************
This e-mail and its attachments contain confidential information from HUAWEI, 
which is intended only for the person  or entity whoseaddress is listed above. 
Any use of the information contained herein in any way (including, but not   
limited to, total or partial disclosure,reproduction, or dissemination) by 
persons other than the intended recipient(s) is  prohibited. If you receive 
this e-mail in error, pleasenotify the sender by phone or email immediately and 
delete it!
***************************************************************************************

_______________________________________________
onap-discuss mailing list
[email protected]
https://lists.onap.org/mailman/listinfo/onap-discuss

Reply via email to