[OpenSIPS-Users] Manually self generate failure

Podrigal, Aron aronp at guaranteedplus.com
Wed Jul 1 03:36:38 CEST 2015


Thanks Jeff, I'll post back how it works for me, and for what use case
I chose what.

On 6/30/15, Jeff Pyle <jeff.pyle at fidelityvoice.com> wrote:
> Since the failure route is triggered by tm, I think you have to t_relay()
> the request for the failure path to be taken.  Maybe you could t_relay() it
> to another proxy with custom headers to indicate how you wanted it to fail,
> or even t_relay() it to the same proxy with care to handle it as you see
> fit.
>
> Or, perhaps this.  Let's say you have
>
> route[dostuff] {
>         stuff();
> }
>
> You could make your failure route available to the main script by writing
> your failure route like this:
>
> failure_route[failedstuff] {
>         route[dostuff];
> }
>
> So that way a true failure would run the same script as if you were to
> manually invoke route[dostuff].
>
> That's a lot of stuff.  Hopefully some of it fits your use case.
>
>
>
> - Jeff
>
>
> On Tue, Jun 30, 2015 at 8:14 PM, Podrigal, Aron <aronp at guaranteedplus.com>
> wrote:
>
>> Is there a way i can manually make a request fail so that my failure
>> route
>> would be invoked? I know this may sound weird, but i encountered some
>> scenarios that this implementation came to my mind. So i want to know if
>> this is possible.
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opensips.org
>> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>>
>>
>


-- 
Aron Podrigal
-
//Be happy :-)



More information about the Users mailing list