db.service_update unused join to compute_node

Bug #1157442 reported by Boris Pavlovic
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Low
Boris Pavlovic

Bug Description

Every time when we are updating service we are making join to compute_node.

We don't use compute_node data from returning value.

And this method is very offen called.
For example if we have about 1000 nodes there will be about 1k services. And each 10 seconds they are updated. So it produces about 100 req/sec.

So it is important to make this method faster.

Tags: db
Changed in nova:
assignee: nobody → Boris Pavlovic (boris-42)
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/24849

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

Reviewed: https://review.openstack.org/24849
Committed: http://github.com/openstack/nova/commit/2b7caba1053f53251074ed1500bf5a8b55c9a78d
Submitter: Jenkins
Branch: master

commit 2b7caba1053f53251074ed1500bf5a8b55c9a78d
Author: Boris Pavlovic <email address hidden>
Date: Wed Mar 20 01:33:00 2013 +0400

    Refactor db.service_destroy and db.service_update methods

    Remove session parameter from db.service_get method

    Optimize db.service_destroy:
    Was:
    1 request with join to get service with compute_node
    1 request to delete service
    1(0) to delete compute_node
    Now:
    1 request (without join) to delete service
    1 request to delete compute_node

    Optimize db.service_update:
    Remove unused join.

    Fixes bug 1157442

    blueprint db-session-cleanup

    Change-Id: Ifcc8fdebfc95daec736464cbc9e16301116540aa

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → grizzly-rc1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: grizzly-rc1 → 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.