L3 agent doing an extreme number of calls pr loop iteration

Bug #1052485 reported by Endre Karlson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
New
Undecided
Unassigned

Bug Description

So what happens each time the agent loops it does:
1. do_single_loop()
2. list_networks() to get the networks which is fine in _fetch_external_net_id()
3. Then it does list_routers() which is fair enough again in do_single_loop() which it uses in a for r in <routers>... loop which is where the bad thing happens
4. Now at this point we're basically doing a vast amount of API calls pr router that we iterate over pr poll.

Now for me I got about 10 networks with routers attached to a external network and it seems to be doing 2-3 api calls pr router. This is causing keystone and quantum to do make the database query amount go up to about ~150 queries in average pr second doing "status" in the mysql client.

This is not just hitting the Quantum API but each poll makes a API call out to keystone as well.

Maybe this should be optimized?

Revision history for this message
Jiajun Liu (ljjjustin) wrote :

yep, you can look at https://bugs.launchpad.net/quantum/+bug/1037246.
IMO, this problem can be resolved when that bug are fixed.

Revision history for this message
dan wendlandt (danwent) wrote :

yeah, we know we need to make this event driven, we just ran out of time in Folsom.

Its not clear to my why each call would result in a request to keystone, as I would expect the client would cache the token across requests. that might be something worth exploring.

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.