request logging in placement api always logs success

Bug #1619690 reported by Chris Dent
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Chris Dent

Bug Description

The request logging in the placement api will always log a status of 200, even when that's not the case because it it getting status from the wrong place. A possible fix is to raise the logging up a level to middleware where it can access the response status more directly (after exceptions).

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

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

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

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

commit 345febe3216a9cb3eb16194c8df981a116a4f9d8
Author: Chris Dent <email address hidden>
Date: Fri Sep 2 14:39:31 2016 +0000

    Move placement api request logging to middleware

    This change moves the request logging in the placement api to
    middleware that is the outermost piece of middleware in the system.

    Without this we end up with a situation where some requests which
    are not successful appear to be logged with success and other
    request do not get logged at all.

    By using middleware we assure that the logging of the beginning of
    the request and _any_ exit of the request will be logged because the
    middleware can be the first and last thing the request interacts
    with.

    Change-Id: I4215cc69cedae5637102b75e0b54fd26acb1826c
    Closes-Bug: #1619690

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

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

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

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

commit 76b53798b68b38b66623047723f588ef1f5fbf73
Author: Chris Dent <email address hidden>
Date: Wed Sep 7 09:23:02 2016 +0000

    [placement] clean up some nits in the requestlog middleware

    In the review of I4215cc69cedae5637102b75e0b54fd26acb1826c there
    were some suggested improvements that did not get implemented
    because we needed the better logging sooner than later.

    This change implements those cleanups including:

    * use ',' instead of '%' for string interpolation in calls to LOG
    * add microversion information to log string, if present

    Change-Id: I6682215d72b644217b5122073d993a99f7830e5b
    Closes-Bug: #1619690

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/nova 14.0.0.0rc1

This issue was fixed in the openstack/nova 14.0.0.0rc1 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/nova 15.0.0.0b1

This issue was fixed in the openstack/nova 15.0.0.0b1 development milestone.

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.