quota-class-update

Bug #1299517 reported by Pavel Kirpichyov
30
This bug affects 5 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Critical
Matt Riedemann
Icehouse
Fix Released
Critical
Matt Riedemann
OpenStack Dashboard (Horizon)
Fix Released
High
Doug Fish
python-novaclient
Fix Released
Undecided
Sergio Cazzolato

Bug Description

Cant update default quota:
root@blade1-1-live:~# nova --debug quota-class-update --ram -1 default

REQ: curl -i 'http://XXX.XXX.XXX.XXX:8774/v2/1eaf475499f8479d94d5ed7a4af68703/os-quota-class-sets/default' -X PUT -H "X-Auth-Project-Id: admin" -H "User-Agent: python-novaclient" -H "Content-Type: application/json" -H "Accept: application/json" -H "X-Auth-Token: 62837311542a42a495442d911cc8b12a" -d '{"quota_class_set": {"ram": -1}}'

New session created for: (http://XXX.XXX.XXX.XXX:8774)
INFO (connectionpool:258) Starting new HTTP connection (1): XXX.XXX.XXX.XXX
DEBUG (connectionpool:375) Setting read timeout to 600.0
DEBUG (connectionpool:415) "PUT /v2/1eaf475499f8479d94d5ed7a4af68703/os-quota-class-sets/default HTTP/1.1" 404 52
RESP: [404] CaseInsensitiveDict({'date': 'Sat, 29 Mar 2014 17:17:32 GMT', 'content-length': '52', 'content-type': 'text/plain; charset=UTF-8'})
RESP BODY: 404 Not Found

The resource could not be found.

DEBUG (shell:777) Not found (HTTP 404)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/novaclient/shell.py", line 774, in main
    OpenStackComputeShell().main(map(strutils.safe_decode, sys.argv[1:]))
  File "/usr/lib/python2.7/dist-packages/novaclient/shell.py", line 710, in main
    args.func(self.cs, args)
  File "/usr/lib/python2.7/dist-packages/novaclient/v1_1/shell.py", line 3378, in do_quota_class_update
    _quota_update(cs.quota_classes, args.class_name, args)
  File "/usr/lib/python2.7/dist-packages/novaclient/v1_1/shell.py", line 3164, in _quota_update
    manager.update(identifier, **updates)
  File "/usr/lib/python2.7/dist-packages/novaclient/v1_1/quota_classes.py", line 44, in update
    'quota_class_set')
  File "/usr/lib/python2.7/dist-packages/novaclient/base.py", line 165, in _update
    _resp, body = self.api.client.put(url, body=body)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 289, in put
    return self._cs_request(url, 'PUT', **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 260, in _cs_request
    **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 242, in _time_request
    resp, body = self.request(url, method, **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 236, in request
    raise exceptions.from_response(resp, body, url, method)
NotFound: Not found (HTTP 404)
ERROR: Not found (HTTP 404)

Revision history for this message
Pavel Kirpichyov (pavel-kirpichyov) wrote :

API was removed since this commit:
https://review.openstack.org/#/c/75535/

Joe Gordon (jogo)
Changed in nova:
status: New → Invalid
Revision history for this message
Vish Ishaya (vishvananda) wrote :

This is a regression from Havana. We should not just remove features with no deprecation cycle and no release notes. I believe we should revert the removal patches.

Changed in nova:
importance: Undecided → Critical
status: Invalid → Triaged
tags: added: icehouse-backport-potential
Revision history for this message
Julie Pichon (jpichon) wrote :

I'm adding a Horizon task so we can track this and put support back in should it be added back to Nova. For reference, Horizon had to remove the panel to update default quotas during the Icehouse RC period (see bug 1292589).

Link to the current ML discussion on the topic: http://lists.openstack.org/pipermail/openstack-dev/2014-May/036002.html

Revision history for this message
Matt Riedemann (mriedem) wrote :

For history, this is the API removal that made it into Icehouse: https://review.openstack.org/#/c/75535/

This is the series that merged on master to remove everything else but the data model:

https://review.openstack.org/#/q/status:merged+project:openstack/nova+branch:master+topic:noquotaclass,n,z

I'm going to revert the series on master first and then revert the API change after that, then cherry pick the API removal revert back to stable/icehouse to get that working again.

I think vishy was talking about adding a Tempest test on master to make sure this isn't removed again in the future without further consideration.

Revision history for this message
Matt Riedemann (mriedem) wrote :
Revision history for this message
Matt Riedemann (mriedem) wrote :
Changed in nova:
status: Triaged → In Progress
assignee: nobody → Matt Riedemann (mriedem)
Changed in horizon:
assignee: nobody → Sergio Cazzolato (sergio-j-cazzolato)
Changed in python-novaclient:
assignee: nobody → Sergio Cazzolato (sergio-j-cazzolato)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-novaclient (master)

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

Changed in python-novaclient:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (master)

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

Changed in horizon:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/96533
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=fc6c14738d2b5e4858977e64fdfba53ea7c07e81
Submitter: Jenkins
Branch: master

commit fc6c14738d2b5e4858977e64fdfba53ea7c07e81
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:02:06 2014 -0700

    Revert "Remove quota_class db API calls"

    This reverts commit 9c285c4bc777141edc80c6a40a3e1ff491aae217.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Change-Id: I69e374cd0363bb7481c5bc96f1ba6415ac50fa81

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/96534
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=86d0cf46715d3c98a49ec08086e7005a12ec5976
Submitter: Jenkins
Branch: master

commit 86d0cf46715d3c98a49ec08086e7005a12ec5976
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:05:49 2014 -0700

    Revert "Remove quota_class params from rest of nova.quota"

    This reverts commit d1442a6aec5e1e20cb35627b77739dbe92770e7a.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Change-Id: I839bb6570f5c189e04e284eda8cde7bc2ac29fdb

Changed in nova:
status: In Progress → Confirmed
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-novaclient (master)

Reviewed: https://review.openstack.org/96568
Committed: https://git.openstack.org/cgit/openstack/python-novaclient/commit/?id=d05da4e985036fa354cc1f2666e39c4aa3213609
Submitter: Jenkins
Branch: master

commit d05da4e985036fa354cc1f2666e39c4aa3213609
Author: Sergio Cazzolato <email address hidden>
Date: Thu May 29 16:48:32 2014 -0300

    Revert "Remove quota-class subcommand"

    This reverts commit 7c11b06bd4e896d891ed3f50c6480bd76a1023bf.

    The quota_class subcommand was used to set default quota values
    so it shouldn't have been removed.

    Related mailing list thread on the topic:
    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Change-Id: I8f392f8e54bef52c1c950f75377e6bb93a41996d
    Partial-Bug: #1299517

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

Reviewed: https://review.openstack.org/96535
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=4b94b4f5f76e56c79a921dbfedf27edb1fd5497f
Submitter: Jenkins
Branch: master

commit 4b94b4f5f76e56c79a921dbfedf27edb1fd5497f
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:06:41 2014 -0700

    Revert "Partially remove quota-class logic from nova.quotas"

    This reverts commit 96c92249a6e48fa391361efd9cdee6eac50b653c.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Change-Id: Iea445877c02205ad64ccbc3864712fd11ba65464

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/96536
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=d9cee6b2ee23dbd4e06a8d57bfeab3ac0f435503
Submitter: Jenkins
Branch: master

commit d9cee6b2ee23dbd4e06a8d57bfeab3ac0f435503
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:07:21 2014 -0700

    Revert "Remove quota-class logic from context and make unit tests pass"

    This reverts commit e25316ecb9c879cd1fe2de0c8a4c4d5a424324ab.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Change-Id: If903863d28fbab74cfe571709a01cd2cdd46d174

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/96537
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=35338d54ad2f76807011a5b666df434eec5369b2
Submitter: Jenkins
Branch: master

commit 35338d54ad2f76807011a5b666df434eec5369b2
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:21:27 2014 -0700

    Revert "Remove broken quota-classes API"

    This reverts commit 7d22153d05c67bb0bf4838efdb17b3360ec2e367.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Conflicts:
     doc/api_samples/all_extensions/extensions-get-resp.json
     doc/api_samples/all_extensions/extensions-get-resp.xml
     nova/tests/integrated/api_samples/all_extensions/extensions-get-resp.xml.tpl

    The conflicts are due to Mark McLoughlin's timestamp-format series
    of changes on master (Juno).

    Also note that quota_classes.py was changed due to
    commit c75a15a4 to rename the NotAuthorized exception
    to Forbidden.

    Change-Id: I7890e6b41d4ebf19944c1d4db65111fcc4c45463

Matt Riedemann (mriedem)
Changed in python-novaclient:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (stable/icehouse)

Fix proposed to branch: stable/icehouse
Review: https://review.openstack.org/99207

Revision history for this message
Matt Riedemann (mriedem) wrote :

Added Tempest since we need to have a nova API test in Tempest for changing default quotas.

Changed in nova:
status: In Progress → Fix Committed
Changed in tempest:
importance: Undecided → Low
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/icehouse)

Reviewed: https://review.openstack.org/99207
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=4c6b0f71c29df1dec8adf7c564c2d5ec4429c956
Submitter: Jenkins
Branch: stable/icehouse

commit 4c6b0f71c29df1dec8adf7c564c2d5ec4429c956
Author: Matt Riedemann <email address hidden>
Date: Thu May 29 08:21:27 2014 -0700

    Revert "Remove broken quota-classes API"

    This reverts commit 7d22153d05c67bb0bf4838efdb17b3360ec2e367.

    The quota_classes API was used to set default quota values
    so it shouldn't have been removed, so reverting a series
    of changes that removed the API and it's internal code.

    Related mailing list thread on the topic:

    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Partial-Bug: #1299517

    Conflicts:
     doc/api_samples/all_extensions/extensions-get-resp.json
     doc/api_samples/all_extensions/extensions-get-resp.xml
     nova/tests/integrated/api_samples/all_extensions/extensions-get-resp.xml.tpl

    The conflicts are due to Mark McLoughlin's timestamp-format series
    of changes on master (Juno).

    Also note that quota_classes.py was changed due to
    commit c75a15a4 to rename the NotAuthorized exception
    to Forbidden.

    Change-Id: I7890e6b41d4ebf19944c1d4db65111fcc4c45463
    (cherry picked from commit 35338d54ad2f76807011a5b666df434eec5369b2)

tags: added: in-stable-icehouse
Revision history for this message
Julie Pichon (jpichon) wrote :

It seems there's already a Tempest task open for this at bug 1325727 (though I see you added a comment there, too).

Revision history for this message
Matt Riedemann (mriedem) wrote :

Yeah I pasted that into the wrong bug. :P

no longer affects: tempest
Julie Pichon (jpichon)
Changed in horizon:
milestone: none → juno-2
David Lyle (david-lyle)
Changed in horizon:
importance: Undecided → High
Michael Still (mikal)
Changed in python-novaclient:
milestone: none → 2.18.0
Michael Still (mikal)
Changed in python-novaclient:
status: Fix Committed → Fix Released
Changed in nova:
milestone: none → juno-2
status: Fix Committed → Fix Released
Changed in horizon:
milestone: juno-2 → juno-3
Thierry Carrez (ttx)
Changed in horizon:
milestone: juno-3 → juno-rc1
Doug Fish (drfish)
Changed in horizon:
assignee: Sergio Cazzolato (sergio-j-cazzolato) → Doug Fish (drfish)
Revision history for this message
Doug Fish (drfish) wrote :

I've rebased/cleaned up the dormant Horizon fix: https://review.openstack.org/96766

Changed in horizon:
assignee: Doug Fish (drfish) → Akihiro Motoki (amotoki)
Akihiro Motoki (amotoki)
Changed in horizon:
assignee: Akihiro Motoki (amotoki) → Doug Fish (drfish)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (master)

Reviewed: https://review.openstack.org/96766
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=b2dd9ded59e84ac22381ca2e576c08fc67aafece
Submitter: Jenkins
Branch: master

commit b2dd9ded59e84ac22381ca2e576c08fc67aafece
Author: Sergio Cazzolato <email address hidden>
Date: Thu May 29 17:10:10 2014 -0300

    Revert "Remove the update default quotas feature"

    This reverts commit ed586a0355fb99a5b1fbeadfc0625f0ceffe8b72.

    The quota_class subcommand in python-novaclient was used to set default
    quota values so it shouldn't have been removed. As now it is being
    restored, the defaults quota panel is being restored too.

    Related mailing list thread on the topic:
    http://lists.openstack.org/pipermail/openstack-dev/2014-May/035383.html

    Resolved merge conflicts by hand in:
    openstack_dashboard/api/cinder.py
    openstack_dashboard/dashboards/admin/info/tabs.py
    openstack_dashboard/dashboards/admin/info/tests.py

    Updated translatable segments to match refactors in
    openstack_dashboard/dashboards/admin/defaults/workflows.py
    openstack_dashboard/dashboards/admin/defaults/tables.py

    Fixed most egregious post-merge styling errors in
    openstack_dashboard/dashboards/admin/defaults/templates/defaults/index.html
    (probably should have been separate, but I just couldn't let it out that way!)

    Removed unrelated file that was allowed to be part of the original commit
    doc/source/topics/settings.rst

    Co-Authored-By: Doug Fish <email address hidden>
    Change-Id: Ic4c4ecec843c7ea9afd0db36ce0eb15952da15b3
    Partial-Bug: #1299517

Thierry Carrez (ttx)
Changed in horizon:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in horizon:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: juno-2 → 2014.2
Thierry Carrez (ttx)
Changed in horizon:
milestone: juno-rc1 → 2014.2
Alan Pevec (apevec)
tags: removed: icehouse icehouse-backport-potential in-stable-icehouse
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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