Should define get_*_count() in l3.RouterPluginBase and raise NotImplementedError

Bug #1083180 reported by Alex Xu
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Low
dan wendlandt
Folsom
Fix Released
Low
dan wendlandt

Bug Description

As the title, we didn't define get_*_count() in l3.RouterPluginBase.
And similar with bug https://code.launchpad.net/bugs/1081259
We should raise NotImplementedError in abstract method.

dan wendlandt (danwent)
Changed in quantum:
status: New → Confirmed
importance: Undecided → Low
Alex Xu (xuhj)
Changed in quantum:
assignee: nobody → Alex Xu (xuhj)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to quantum (master)

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

Changed in quantum:
assignee: Alex Xu (xuhj) → dan wendlandt (danwent)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to quantum (master)

Reviewed: https://review.openstack.org/16989
Committed: http://github.com/openstack/quantum/commit/78eb1a0d53f099e42e1ffb370da8561a0c5d35bb
Submitter: Jenkins
Branch: master

commit 78eb1a0d53f099e42e1ffb370da8561a0c5d35bb
Author: Dan Wendlandt <email address hidden>
Date: Tue Nov 27 09:53:28 2012 -0800

    fix so cisco plugin db model to not override count methods

    bug 1083696

    also fixes bug 1083180, which has L3 plugin base class implement
    get_*_count methods and raise
    NotImplemented, which is the "right" thing to do from a
    code-as-documentation perspective.

    Change-Id: I0367953bcea930b1ca70e416d3de22eeea1aa99d

Changed in quantum:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to quantum (stable/folsom)

Fix proposed to branch: stable/folsom
Review: https://review.openstack.org/17000

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to quantum (stable/folsom)

Reviewed: https://review.openstack.org/16952
Committed: http://github.com/openstack/quantum/commit/ca7fc10dac532fdea5398b394ac3e58b1c3d8791
Submitter: Jenkins
Branch: stable/folsom

commit ca7fc10dac532fdea5398b394ac3e58b1c3d8791
Author: Dan Wendlandt <email address hidden>
Date: Tue Nov 27 13:14:54 2012 -0800

    Use DB count to get resource counts.

    Fixes bug 1075369, and includes bugs 1081259, 1083696 which fixed
    regression in the original version of this patch and bug 1083180
    which improves the documentation of the original patch.

    During quota check we used to simply retrieve the entire collection
    of resources from the database, then counting them in Python. This
    patch introduces a specialized _get_collection_count() method, which
    instead take advantage of the DB's built-in count capabilities.

    In order to take advantage of this, plugins can now implement
    get_*_count() methods for their resources. This is used (if present)
    by the quota checking function.

    Change-Id: Idc347cfacc363f2cac47356296514fe735625f29

tags: added: in-stable-folsom
Thierry Carrez (ttx)
Changed in quantum:
milestone: none → grizzly-2
status: Fix Committed → Fix Released
Mark McLoughlin (markmc)
tags: removed: in-stable-folsom
Thierry Carrez (ttx)
Changed in quantum:
milestone: grizzly-2 → 2013.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.