v2 image-update does not handle some schema properties properly
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Glance |
Fix Released
|
Medium
|
Kamil Rykowski | ||
Glance Client |
Fix Released
|
Medium
|
Kamil Rykowski |
Bug Description
Step1: Create an empty image using api v1 or v2.
Step2: Use glanceclient with v2 API to update image property called "architecture":
glance --os-image-
This will show following error message:
<html>
<head>
<title>409 Conflict</title>
</head>
<body>
<h1>409 Conflict</h1>
There was a conflict when trying to complete your request.<br /><br />
Property architecture does not exist.
</body>
</html> (HTTP 409)
The error shows up, because the client sends to glance API following data:
[{"patch: "/architecture", "value": "x86", "op": "replace"}]
instead of
[{"patch: "/architecture", "value": "x86", "op": "add"}]
The issue is somehow related to overridden patch method in SchemaBasedModel class, which propagates non existing properties from schema properties.
Changed in glance: | |
status: | New → In Progress |
Changed in python-glanceclient: | |
status: | New → In Progress |
description: | updated |
Changed in glance: | |
assignee: | nobody → Kamil Rykowski (kamil-rykowski) |
Changed in python-glanceclient: | |
assignee: | nobody → Kamil Rykowski (kamil-rykowski) |
Changed in glance: | |
status: | In Progress → Fix Committed |
Changed in glance: | |
importance: | Undecided → Medium |
Changed in python-glanceclient: | |
importance: | Undecided → Medium |
Changed in glance: | |
milestone: | none → juno-rc2 |
Changed in glance: | |
milestone: | juno-rc2 → 2014.2 |
Changed in python-glanceclient: | |
status: | Fix Committed → Fix Released |
Fix proposed to branch: master /review. openstack. org/123738
Review: https:/