txlb.ProxyService.getEnabledGroup does not always return an enabled group

Bug #255498 reported by Shaival Varma
2
Affects Status Importance Assigned to Milestone
txLoadBalancer
Fix Committed
Medium
Duncan McGreggor

Bug Description

This report is for txLoadBalancer-1.1.0

getEnabledGroup determines determines the enabled groups on line 94 with:
groups = [x for x in self.groups.values() if x.isEnabled]

It expects x.isEnabled to evaluate to True only for enabled groups.

However, when txlb.application.director.configuredProxyManagerFactory instantiates txlb.model.ProxyGroup (line 41-42), it passes in groupConf.isEnabled, which is a bound method. When this is evaluated in the list comprehension shown above, it always evaluates to True for all groups.

The fix appears to be to change:
groupConf.isEnabled
to:
groupConf.isEnabled()

Revision history for this message
Shaival Varma (svarma-shff) wrote :
Changed in txloadbalancer:
assignee: nobody → oubiwann
importance: Undecided → Medium
Revision history for this message
Duncan McGreggor (oubiwann) wrote :

Shaival,

Thanks for your fix! And sorry it took so long to get to this one. I was away in the Rocky Mountains when this ticket was submitted, and had forgotten it until just now.

The fix had been committed in trunk, r210.

Changed in txloadbalancer:
status: New → Fix Committed
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.