Adding a function to allow either an MI command to update the weighting or 
having the probing pull the data from the sources was my first thought, however 
I’m hoping to avoid having to run customized modules just to prevent the need 
to deal with forward compatibility problems down the road.  I’d almost rather 
build my own load distribution mechanism than deal with that.

Brooks Bridges | Sr. Voice Services Engineer
O1 Communications
5190 Golden Foothill Pkwy
El Dorado Hills, CA 95762
office: 916.235.2097 | main: 888.444.1111, Option 2
email: bbrid...@o1.com<mailto:bbrid...@o1.com> | web: 
www.o1.com<http://www.o1.com/>

From: sr-users [mailto:sr-users-boun...@lists.sip-router.org] On Behalf Of 
SamyGo
Sent: Thursday, March 24, 2016 11:38 AM
To: Kamailio (SER) - Users Mailing List
Subject: Re: [SR-Users] dynamic weighting for dispatcher

Hi Brooks,

While I was trying to figure issue out with my dispatcher issue here is 
something that I think might work for you. It do requires modifying little bit 
C code to pull some weight from a redis/memcache of remote destination and use 
that value instead. Somewhere in this function of dispatcher module possibly:

Ref: 
https://github.com/kamailio/kamailio/blob/master/modules/dispatcher/dispatch.c

/*! \brief
* Timer for checking probing destinations
*
* This timer is regularly fired.
*/
void ds_check_timer(unsigned int ticks, void* param)

Since this is probing at regular intervals, code is already there all it needs 
is to get a number and set it as the destination's weight.


Just my crazy idea, but Daniel or Kamailio team might suggest something much 
better than this.

Regards,
Sammy


On Thu, Mar 24, 2016 at 12:30 PM, Brooks Bridges 
<bbrid...@o1.com<mailto:bbrid...@o1.com>> wrote:
So I’m building a load balancer solution that needs to monitor remote devices 
at a specific interval via snmp for certain data (channels and cps) and use 
that data to create a dynamically updated weight for each of the destinations.  
I can’t find any reasonable mechanism for updating the weight attribute in the 
dispatcher module itself without having to do some hacky “update the database 
column then trigger dispatcher.reload” script, which I very much want to avoid.

Is this something I should just be thinking of ditching the dispatcher module 
and rolling my own design or am I missing something obvious?

Brooks Bridges | Sr. Voice Services Engineer
O1 Communications
5190 Golden Foothill Pkwy
El Dorado Hills, CA 95762
office: 916.235.2097 | main: 888.444.1111, Option 2
email: bbrid...@o1.com<mailto:bbrid...@o1.com> | web: 
www.o1.com<http://www.o1.com/>


_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org<mailto:sr-users@lists.sip-router.org>
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

Reply via email to