Update l7policy position failed when the policy position is 2147483647

Bug #1705163 reported by huangshan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
octavia
Invalid
Low
Unassigned

Bug Description

Since position is a sequential sequence starting at 1 ,and the query for a listener from the database, the result of the return is sorted by position. So from l7polices.pop (position-1) is to find the policy. The exception is the position for the 2147483647 policy, which is the maximum position, it does not and other policy position composed of a continuous sequence.

The neutron-server log is as follows:

2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource [req-2bf4ea84-89de-4eee-95c8-7ec715797c0e 142d8663efce464c89811c63e45bd82e f21a9c86d7114bf99c711f4874d80474 - - -] update failed: No details.
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource Traceback (most recent call last):
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/api/v2/resource.py", line 79, in resource
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource result = method(request=request, **args)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/api/v2/base.py", line 604, in update
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource return self._update(request, id, body, **kwargs)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/db/api.py", line 88, in wrapped
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource setattr(e, '_RETRY_EXCEEDED', True)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource self.force_reraise()
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource six.reraise(self.type_, self.value, self.tb)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/db/api.py", line 84, in wrapped
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource return f(*args, **kwargs)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_db/api.py", line 151, in wrapper
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource ectxt.value = e.inner_exc
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource self.force_reraise()
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource six.reraise(self.type_, self.value, self.tb)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_db/api.py", line 139, in wrapper
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource return f(*args, **kwargs)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/db/api.py", line 124, in wrapped
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource traceback.format_exc())
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource self.force_reraise()
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource six.reraise(self.type_, self.value, self.tb)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/db/api.py", line 119, in wrapped
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron/api/v2/base.py", line 652, in _update
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource obj = obj_updater(request.context, id, **kwargs)
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource File "/usr/lib/python2.7/site-packages/neutron_lbaas/services/loadbalancer/plugin.py", line 915, in update_l7policy
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource raise exc
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource IndexError: pop index out of range
2017-07-19 10:55:02.324 44136 ERROR neutron.api.v2.resource

huangshan (huangshan)
affects: openstack-gate → octavia
huangshan (huangshan)
description: updated
tags: added: lbaas
Changed in octavia:
importance: Undecided → Critical
importance: Critical → Low
Revision history for this message
zhaobo (zhaobo6) wrote :

Can not repro on master.

Revision history for this message
Gregory Thiemonge (gthiemonge) wrote : auto-abandon-script

Abandoned after re-enabling the Octavia launchpad.

Changed in octavia:
status: New → Invalid
tags: added: auto-abandon
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.