← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1261964] [NEW] should handle extra parameters as invalid via update_host API

 

Public bug reported:

On update_host API(update() in nova/api/openstack/compute/contrib/hosts.py),
there is a different behavior between JSON request and XML request.

If JSON request has extra API parameters(not "status", "maintenance_mode"),
Nova returns a BadRequest response with message "Invalid update setting: <key>".
But if XML request, Nova does not return a BadRequest response and continues
its work.

This behavior seems wrong from the viewpoint of API consistency.


Note:
This is due to HostUpdateDeserializer class, the class' method ignores extra API
parameters and deserializes right parameters only.
This difference happens in Nova v2 API, and it has been fixed in Nova v3 API.

** Affects: nova
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1261964

Title:
  should handle extra parameters as invalid via update_host API

Status in OpenStack Compute (Nova):
  New

Bug description:
  On update_host API(update() in nova/api/openstack/compute/contrib/hosts.py),
  there is a different behavior between JSON request and XML request.

  If JSON request has extra API parameters(not "status", "maintenance_mode"),
  Nova returns a BadRequest response with message "Invalid update setting: <key>".
  But if XML request, Nova does not return a BadRequest response and continues
  its work.

  This behavior seems wrong from the viewpoint of API consistency.

  
  Note:
  This is due to HostUpdateDeserializer class, the class' method ignores extra API
  parameters and deserializes right parameters only.
  This difference happens in Nova v2 API, and it has been fixed in Nova v3 API.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1261964/+subscriptions


Follow ups

References