Hi Razvan, thank you for the reply. I don't necessarily need expiration of 
subscriptions to rabbit or the timer route per se. I'm just trying to figure 
out (with the existing capabilities) how to make opensips fail to another 
member in the rabbit cluster in the event that the current node dies. My first 
thought was that you could simply stack entry points like:

subscribe_event("E_ACC_CDR", 
"rabbitmq:rabbitmq:rabbit@192.168.2.30;rabbitmq:rabbit@192.168.2.31;rabbitmq:rabbit@192.168.2.33/cdr1")

However, it sounds like that's not in the present implementation of the rabbit 
module. 

So my second thought was to trick opensips and put HAProxy between it and 
Rabbit, which works, but if I fail an HAProxy via corosync to the other HAproxy 
something with the subscription breaks. Since it looked like the two options 
were either put the subscribes in the startup route (only happens once so 
probably won't failover) OR use the timer route to subscribe (which is what i'm 
doing) I figured that in the event of an HAProxy failure, I might miss a few 
messages but on the next timer fire opensips would resubscribe to haproxy which 
would relay that to the appropriate rabbit server (I haven't failed over any 
rabbit servers in this scenario so haproxy2 is talking to the same rabbit 
server as haproxy1. All i'm doing is killing haproxy1 right now and letting the 
VIP go to haproxy2). However it doesn't look like this is working and I can't 
tell if its because the subscription isn't happening, OR it is happening but 
opensips sees it already exists in the
 subscribers list and does nothing (I think this is the case). If this IS the 
case perhaps a solution would be to kill the subscriber entry on new subscribe. 
If I'm way off, let me know, I'd really like to figure this out. Am I going 
about this all wrong? How would you handle a rabbit node failure?

Regards

_______________________________________________
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

Reply via email to