giupand left a comment (kamailio/kamailio#4330)
It doesn't work well... The goal is: when the destination 192.168.2.222 is not reachable from its socket goes down. DEST 1: URI: sip:192.168.2.222:5060 its SOCKET: udp:192.168.2.250:5060 DEST 2: URI: sip:192.168.2.222:5060 its SOCKET: udp:192.168.2.246:5060
when DEST 1 isnt reachable from udp:192.168.2.250:5060, it goes down and state will be IP if DEST 2 is reachable from udp:192.168.2.246:5060, it stay in AP state
when also DEST 2 isnt reachable from udp:192.168.2.246:5060, it goes down and state will be IP
With your modify (//return 0), when the frist destination goes down both destinations goes in IP state (see dispatcher.list output) instead should be only first destination in IP state because the second destination is still reachable from udp:192.168.2.246:5060 socket.
``` SET: { ID: 29 TARGETS: { DEST: { URI: sip:192.168.2.222:5060 FLAGS: IP PRIORITY: 21 ATTRS: { BODY: ping_from=sip:27@domain.com;socket=udp:192.168.2.250:5060 DUID: <null string> MAXLOAD: 0 WEIGHT: 0 RWEIGHT: 0 SOCKET: udp:192.168.2.250:5060 SOCKNAME: <null string> OBPROXY: <null string> } RUNTIME: { DLGLOAD: 0 } } DEST: { URI: sip:192.168.2.222:5060 FLAGS: IP PRIORITY: 12 ATTRS: { BODY: ping_from=sip:28@domain.com;socket=udp:192.168.2.246:5060 DUID: <null string> MAXLOAD: 0 WEIGHT: 0 RWEIGHT: 0 SOCKET: udp:192.168.2.246:5060 SOCKNAME: <null string> OBPROXY: <null string> } RUNTIME: { DLGLOAD: 0 } } } }
```