Josh-- Many thanks!
I see: else msec_time = (1 << (tsx->retransmit_count)) * pjsip_cfg()->tsx.t1; which doubles the waiting time each try.... and in the UAC code, with a small addition, I get: if (msec_time > pjsip_cfg()->tsx.t2 && tsx->method.id != PJSIP_REGISTER_METHOD && tsx->method.id != PJSIP_INVITE_METHOD) { msec_time = pjsip_cfg()->tsx.t2; } which caps the wait time to 4 sec. for anything but invite, and *now*, including register. Which should give me the effect I'm seeking. (avg ~4.5/minute) I've tested it out, and it works fine. I see the initial xmit, retries at .5, 1, 2, 4, 8, 16, for a total of 31.5 sec, followed with a 61 second gap, and the process repeats itself. Total cycle time is 92.5 sec. 7 tries in 92.5 sec yields an avg of 4.5/minute. Again, thanks! murf On Tue, May 2, 2017 at 4:17 PM, Joshua Colp <jc...@digium.com> wrote: > On Tue, May 2, 2017, at 07:07 PM, Steve Murphy wrote: > > <snip> > > > > > I notice that pjsip in asterisk seems to follow the same pattern of > > retries: > > first, a half-second wait, then a retry, then a full second wait, then > > a retry, then a 2 second wait, and several 4-second waits until half a > > minute or so, > > and after 60 seconds, (61 seconds?) the cycle starts over. > > > > I have spent hours looking for this algorithm first in the asterisk code, > > then in pjproject. > > The docs for pjproject say: > > > > (section 8.1.2: Timers and Retransmissions) > > > > β "Application can change the interval value of timers only on a > > global > > basis > > (perhaps even only during compilation)." > > > > βAny hints as to where this code is located? > > The code itself is in the transaction layer of PJSIP at > pjsip/src/pjsip/sip_transaction.c - specifically the > tsx_resched_retransmission function. > > -- > Joshua Colp > Digium, Inc. | Senior Software Developer > 445 Jan Davis Drive NW - Huntsville, AL 35806 - US > Check us out at: www.digium.com & www.asterisk.org > > -- > _____________________________________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > asterisk-dev mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-dev -- Steve Murphy ParseTree Corporation 57 Lane 17 Cody, WY 82414 β murf at parsetree dot com β 307-899-0510
-- _____________________________________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-dev mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-dev