updating address pairs with xml doesn't work

Bug #1229954 reported by Aaron Rosen
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
Hua Zhang

Bug Description

Works fine: neutron port-update 493199d2-d792-4017-b015-894e85a8e32a --allowed-address-pairs list=true type=dict ip_address=10.0.0.1

Generates:
    [{u'ip_address': u'10.0.0.1'}]

neutron port-update 493199d2-d792-4017-b015-894e85a8e32a --allowed-address-pairs list=true type=dict ip_address=10.0.0.1 --request-format xml

Generates:
    {'allowed_address_pair': {'ip_address': '10.0.0.1'}}

2013-09-24 14:10:34.021 19471 ERROR neutron.api.v2.resource [-] update failed
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource Traceback (most recent call last):
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/resource.py", line 84, in resource
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource result = method(request=request, **args)
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 460, in update
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource allow_bulk=self._allow_bulk)
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 589, in prepare_request_body
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource attr_vals['validate'][rule])
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/extensions/allowedaddresspairs.py", line 53, in _validate_allowed_address_pairs
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource raise AllowedAddressPairsMissingIP()
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource AllowedAddressPairsMissingIP: AllowedAddressPair must contain ip_address
2013-09-24 14:10:34.021 19471 TRACE neutron.api.v2.resource

Hua Zhang (zhhuabj)
Changed in neutron:
assignee: nobody → Hua Zhang (zhhuabj)
Revision history for this message
Akihiro Motoki (amotoki) wrote :

TestOpenvswitchSGServerRpcCallBackXML in OVS plugin test actually fails.
It is hidden by the bug 1230083.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.openstack.org/51375

Changed in neutron:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/51778

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/51375
Committed: http://github.com/openstack/neutron/commit/893e10b0add63b364eb6d92715967c45028fa692
Submitter: Jenkins
Branch: master

commit 893e10b0add63b364eb6d92715967c45028fa692
Author: zhhuabj <email address hidden>
Date: Sat Oct 12 17:31:38 2013 +0800

    Updating address pairs with xml doesn't work

    Below command can't work because list element
    "allowed_address_pairs" hasn't been updated
    into the varaiable "attr.PLURALS"
    "neutron port-update <port-uuid> \
    --allowed-address-pairs list=true type=dict \
    ip_address=10.0.0.1 --request-format xml"

    Change-Id: I0d7dcca5f4848bc968f5c86fbeb46569c70c8fcd
    Closes-Bug: #1229954

Changed in neutron:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to neutron (master)

Reviewed: https://review.openstack.org/51778
Committed: http://github.com/openstack/neutron/commit/e5158eb918649eb04d6e6406f01ba39c9a36d94b
Submitter: Jenkins
Branch: master

commit e5158eb918649eb04d6e6406f01ba39c9a36d94b
Author: zhhuabj <email address hidden>
Date: Tue Oct 15 13:55:13 2013 +0800

    Enable one disabled tests in NEC plugin that blocked by 1229954

    Enable the disabled tests in NEC plugin that blocked by 1229954
    https://github.com/openstack/neutron/blob/master/neutron
    /tests/unit/nec/test_security_group.py#L64

    Change-Id: Id15c5b431773d05f13201cdcd126ff2fa9f6aa06
    Related-Bug: #1229954

Changed in neutron:
milestone: none → icehouse-1
tags: added: havana-backport-potential neutron-core xml
Changed in neutron:
importance: Undecided → Medium
Thierry Carrez (ttx)
Changed in neutron:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in neutron:
milestone: icehouse-1 → 2014.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.