[asterisk-bugs] [Asterisk 0010942]: [PATCH] Add a new queue strategy: weighted random (wrandom)
noreply at bugs.digium.com
noreply at bugs.digium.com
Thu Oct 11 08:39:39 CDT 2007
A NOTE has been added to this issue.
======================================================================
http://bugs.digium.com/view.php?id=10942
======================================================================
Reported By: julianjm
Assigned To:
======================================================================
Project: Asterisk
Issue ID: 10942
Category: Applications/app_queue
Reproducibility: N/A
Severity: feature
Priority: normal
Status: new
Asterisk Version: SVN
SVN Branch (only for SVN checkouts, not tarball releases): 1.4
SVN Revision (number only!): 85355
Disclaimer on File?: N/A
Request Review:
======================================================================
Date Submitted: 10-10-2007 17:43 CDT
Last Modified: 10-11-2007 08:39 CDT
======================================================================
Summary: [PATCH] Add a new queue strategy: weighted random
(wrandom)
Description:
Random strategy, but using penaly as a weight. Basically, the higher the
penalty, the less probability to receive calls from the queue.
[600]
strategy=wrandom
member=SIP/100,0
member=SIP/101,1
member=SIP/102,2
When calculating the metric for each round, we use this formula:
metric=ast_random() % ((penalty+1)*1000)
penalty 0 => metric between 0 and 999
penalty 1 => metric between 0 and 1999
penalty 2 => metric between 0 and 2999
The member with lower metric gets the next call.
======================================================================
----------------------------------------------------------------------
ibc - 10-11-07 08:39
----------------------------------------------------------------------
I think this strategy=wrandom can be really useful.
Issue History
Date Modified Username Field Change
======================================================================
10-11-07 08:39 ibc Note Added: 0071811
======================================================================
More information about the asterisk-bugs
mailing list