RE: [reSIProcate] Sending 100 trying
Scott,
This most certainly must be my problem! In my main routine, I create an
instance of the stack and my application. I call run on the stack
thread and run on my instance. I presumed that stackThread.run() would
call stack->process(). Where is the best place in my thread() routine
to call stack->process()? At the beginning of my thread() routine?
Should I be doing this in a different way?
Thanks in advance!
Michael Baj
...
try
{
// create the SipDirector Application
SipDirector sd(stack, args);
// add domains so the stack can listen
addDomains(sd, args);
/* initialize the stack thead and DUM */
resip::StackThread stackThread(stack);
stack.registerTransactionUser(sd);
/* Make it all go */
stackThread.run();
sd.run();
/* wait until we are interrupted by signal */
while (!sd.isShutdown())
{
usleep(100000);
}
/* clean up */
sd.shutdown();
stackThread.shutdown();
sd.join();
stackThread.join();
}
catch (const std::exception& e)
{
ERR("%s", e.what());
return EXIT_FAILURE;
}
-----Original Message-----
From: Scott Godin [mailto:slgodin@xxxxxxxxxxxx]
Sent: Tuesday, May 16, 2006 9:06 AM
To: Michael Baj; resiprocate-devel@xxxxxxxxxxxxxxxxxxx
Subject: RE: [reSIProcate] Sending 100 trying
Are you calling stack->process() while you are waiting for 200ms? The
stack timers will not fire unless you give the stack cycles.
> -----Original Message-----
> From: resiprocate-devel-bounces@xxxxxxxxxxxxxxxxxxx
[mailto:resiprocate-
> devel-bounces@xxxxxxxxxxxxxxxxxxx] On Behalf Of Michael Baj
> Sent: Monday, May 15, 2006 4:29 PM
> To: resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> Subject: RE: [reSIProcate] Sending 100 trying
>
> Jason,
>
> I have uncommented the stack debug statements that were originally in
> the code under ProcessServerInvite(). My UAS is set up not to send
any
> response until 200 ms after receiving the INVITE. Below is the debug
> output of my call flow. As you can see, the 100 trying timer is
> triggered, but is not being processed because the transaction state is
> not in the "Trying" state. When the TransactionState gets created
(line
> 261, TransactionState.cxx), it is created with the state of Trying.
> However, 5 lines, lower, the state is changed to "Proceeding". It my
> guess that this is not allowing the timer to be processed. What are
> your thoughts?
>
> Thanks,
> Mike
>
> STACK | 20060515-161746.631 | mbaj-dev | sipdirector |
RESIP:TRANSACTION
> | 21696 | 29723568 | TransactionState.cxx:183 | Found matching
> transaction for Timer: Timer Trying 80 ->
> tid=-1-4invite1-21716@xxxxxxxxxxxxxxxxxxxx [ ServerInvite/Proceeding
> unreliable target=[ V4 192.168.10.55:5062 UDP target
domain=unspecified
> received on: Transport: [ V4 0.0.0.0:5060 UDP target
domain=unspecified
> connectionId=0 ] connectionId=0 ]]
> STACK | 20060515-161746.632 | mbaj-dev | sipdirector |
RESIP:TRANSACTION
> | 21696 | 29723568 | TransactionState.cxx:920 |
> TransactionState::processServerInvite: Timer: Timer Trying 80
> STACK | 20060515-161746.632 | mbaj-dev | sipdirector |
RESIP:TRANSACTION
> | 21696 | 29723568 | TransactionState.cxx:1145 | TimerTrying fired.
Not
> in Trying state. Ignoring
> DEBUG | 20060515-161746.791 | mbaj-dev | sipdirector | RESIP:TRANSPORT
|
> 21696 | 29723568 | Transport.cxx:259 | incoming from: [ V4
> 192.168.10.55:5070 UDP target domain=unspecified received on:
Transport:
> [ V4 0.0.0.0:5060 UDP target domain=unspecified connectionId=0 ]
> connectionId=0 ]
>
> -----Original Message-----
> From: jason.fischl@xxxxxxxxx [mailto:jason.fischl@xxxxxxxxx] On Behalf
> Of Jason Fischl
> Sent: Monday, May 15, 2006 4:05 PM
> To: Michael Baj
> Cc: resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> Subject: Re: [reSIProcate] Sending 100 trying
>
> The underlying stack sends the 100 after 80ms if no other response is
> sent by the UAS.
>
> On 5/15/06, Michael Baj <mbaj@xxxxxxxxxxxxxxxxxxxxxxx> wrote:
> >
> >
> >
> >
> > I'm still stuck on this 100 Trying problem that I'm having. I have
> noticed
> > that in my code, I am receiving 100 Trying, but only in the case of
> when I
> > receive a retransmission of an INVITE. I've been pouring over the
> > reciprocate code, and it seems that this is behaving as designed.
> However,
> > I still do not receive any 100 Trying after the initial INVITE is
> received.
> > I am using sipp to generate and terminate requests for my test, and
I
> have
> > inserted a delay of 200 ms after sending the 100 trying, and am
still
> not
> > receiving a 100 Trying.
> >
> >
> >
> > This is the DEBUG trace from when I receive the invite, up until I
> receive
> > the 100 Trying from my terminating device. As you can see, there is
> no 100
> > Trying being generated by the stack. Is there something that I need
> to
> > register for in the TransactionUser to enable this behavior?
> >
> >
> >
> >
> > Thanks in advance!
> >
> > Michael Baj
> >
> >
> >
> >
> > DEBUG | 20060515-144250.322 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | UdpTransport.cxx:57 | Sending message on udp.
> >
> > DEBUG | 20060515-144250.323 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | Transport.cxx:259 | incoming from: [ V4
> 192.168.10.55:5062
> > UDP target domain=unspecified received on: Transport: [ V4
> 0.0.0.0:5060 UDP
> > target domain=unspecified connectionId=0 ] connectionId=0 ]
> >
> > DEBUG | 20060515-144250.323 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TransactionUser.cxx:66 | Checking if SipReq:
INVITE
> > 1111400000@xxxxxxxxxxxxx:5060
> > tid=-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx cseq=INVITE
> > contact=3128652501@xxxxxxxxxxxxx:5062 / 1 from(wire) is for me
> >
> > DEBUG | 20060515-144250.324 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TransactionUser.cxx:71 | Checking rule...
> >
> > DEBUG | 20060515-144250.324 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | MessageFilterRule.cxx:42 | Matching rule for
INVITE
> > sip:1111400000@xxxxxxxxxxxxx:5060 SIP/2.0
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5062;branch=z9hG4bK-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx;r
> port=5062
> >
> > Max-Forwards: 70
> >
> > Contact: <sip:3128652501@xxxxxxxxxxxxx:5062>
> >
> > To: <sip:1111400000@xxxxxxxxxxxxx:5060>
> >
> > From:
> >
>
"3128652501"<sip:3128652501@xxxxxxxxxxxxx:5062>;tag=123abc1from1-3576@19
> 2.168.10.55
> >
> > Call-ID: 1-3576@xxxxxxxxxxxxx
> >
> > CSeq: 1 INVITE
> >
> > Subject: Performance Test
> >
> > Content-Type: application/sdp
> >
> > Content-Length: 138
> >
> >
> >
> > v=0
> >
> > o=user1 53655765 2353687637 IN IP4 192.168.10.55
> >
> > s=-
> >
> > c=IN IP4 192.168.10.55
> >
> > t=0 0
> >
> > m=audio 10008 RTP/AVP 0
> >
> > a=rtpmap:0 PCMU/8000
> >
> >
> >
> > DEBUG | 20060515-144250.325 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TransactionUser.cxx:74 | Match!
> >
> > DEBUG | 20060515-144250.325 | mbaj-dev | sipdirector | RESIP | 3556
|
> > 29871024 | Helper.cxx:302 | Helper::makeResponse(SipReq: INVITE
> > 1111400000@xxxxxxxxxxxxx:5060
> > tid=-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx cseq=INVITE
> > contact=3128652501@xxxxxxxxxxxxx:5062 / 1 from(wire) code=100
reason=
> >
> > DEBUG | 20060515-144250.326 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TimerQueue.cxx:85 | Adding timer: Timer Trying
> > tid=-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx ms=80
> >
> > DEBUG | 20060515-144250.326 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TransactionState.cxx:1623 | Send to TU: TU:
> SipDirector
> > size=0 INVITE sip:1111400000@xxxxxxxxxxxxx:5060 SIP/2.0
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5062;branch=z9hG4bK-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx;r
> port=5062
> >
> > Max-Forwards: 70
> >
> > Contact: <sip:3128652501@xxxxxxxxxxxxx:5062>
> >
> > To: <sip:1111400000@xxxxxxxxxxxxx:5060>
> >
> > From:
> >
>
"3128652501"<sip:3128652501@xxxxxxxxxxxxx:5062>;tag=123abc1from1-3576@19
> 2.168.10.55
> >
> > Call-ID: 1-3576@xxxxxxxxxxxxx
> >
> > CSeq: 1 INVITE
> >
> > Subject: Performance Test
> >
> > Content-Type: application/sdp
> >
> > Content-Length: 138
> >
> >
> >
> > v=0
> >
> > o=user1 53655765 2353687637 IN IP4 192.168.10.55
> >
> > s=-
> >
> > c=IN IP4 192.168.10.55
> >
> > t=0 0
> >
> > m=audio 10008 RTP/AVP 0
> >
> > a=rtpmap:0 PCMU/8000
> >
> >
> >
> > DEBUG: Got: SipReq: INVITE 1111400000@xxxxxxxxxxxxx:5060
> > tid=-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx cseq=INVITE
> > contact=3128652501@xxxxxxxxxxxxx:5062 / 1 from(wire)
> >
> > DEBUG: Trying to match 3128652501 as Forced Route
> >
> > DEBUG: getAssignedCsg: User 3128652501 not assigned to CSG
> >
> > DEBUG: Sending INVITE to sip:192.168.10.55:5070
> >
> > DEBUG: Sending SipReq: INVITE 1111400000@xxxxxxxxxxxxx:5070
> > tid=f0a0343925a30f66 cseq=INVITE
contact=3128652501@xxxxxxxxxxxxx:5062
> / 1
> > from(wire)
> >
> > DEBUG | 20060515-144250.355 | mbaj-dev | sipdirector | RESIP | 3556
|
> > 40360880 | SipStack.cxx:276 | SEND: SipReq: INVITE
> > 1111400000@xxxxxxxxxxxxx:5070 tid=f0a0343925a30f66 cseq=INVITE
> > contact=3128652501@xxxxxxxxxxxxx:5062 / 1 from(wire)
> >
> > DEBUG | 20060515-144250.381 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TimerQueue.cxx:85 | Adding timer: Timer B
> > tid=f0a0343925a30f66 ms=32000
> >
> > DEBUG | 20060515-144250.381 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | TransportSelector.cxx:247 | Looking up dns entries
> for
> > sip:1111400000@xxxxxxxxxxxxx:5070
> >
> > DEBUG | 20060515-144250.381 | mbaj-dev | sipdirector | RESIP:DNS |
> 3556 |
> > 29871024 | DnsResult.cxx:184 | DnsResult::lookup
> > sip:1111400000@xxxxxxxxxxxxx:5070
> >
> > DEBUG | 20060515-144250.382 | mbaj-dev | sipdirector | RESIP:DNS |
> 3556 |
> > 29871024 | DnsResult.cxx:318 | Numeric result so return immediately:
[
> V4
> > 192.168.10.55:5070 UDP target domain=192.168.10.55 connectionId=0 ]
> >
> > DEBUG | 20060515-144250.382 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TimerQueue.cxx:85 | Adding timer: Timer A
> > tid=f0a0343925a30f66 ms=500
> >
> > DEBUG | 20060515-144250.382 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | TransportSelector.cxx:483 | Looked up source for
> > destination: [ V4 192.168.10.55:5070 UDP target domain=192.168.10.55
> > connectionId=0 ] -> [ V4 192.168.10.55:5060 UDP target
> domain=192.168.10.55
> > connectionId=0 ] sent-by= sent-port=5060
> >
> > DEBUG | 20060515-144250.383 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | TransportSelector.cxx:752 | findTransport([ V4
> > 192.168.10.55:5060 UDP target domain=192.168.10.55 connectionId=0 ])
> >
> > DEBUG | 20060515-144250.383 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | TransportSelector.cxx:771 | findTransport (any
> interface)
> > => Transport: [ V4 0.0.0.0:5060 UDP target domain=unspecified
> connectionId=0
> > ]
> >
> > DEBUG | 20060515-144250.384 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | TransportSelector.cxx:670 | Transmitting to [ V4
> > 192.168.10.55:5070 UDP target domain=192.168.10.55 received on:
> Transport: [
> > V4 0.0.0.0:5060 UDP target domain=unspecified connectionId=0 ]
> > connectionId=0 ] tlsDomain= via [ V4 192.168.10.55:5060 UDP target
> > domain=192.168.10.55 connectionId=0 ]INVITE
> > sip:1111400000@xxxxxxxxxxxxx:5070 SIP/2.0
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5060;branch=z9hG4bK-d87543-f0a0343925a30f66-1--d87543-;rpo
> rt
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5062;branch=z9hG4bK-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx;r
> port=5062
> >
> > Max-Forwards: 70
> >
> > Contact: <sip:3128652501@xxxxxxxxxxxxx:5062>
> >
> > To: <sip:1111400000@xxxxxxxxxxxxx:5060>
> >
> > From:
> >
>
"3128652501"<sip:3128652501@xxxxxxxxxxxxx:5062>;tag=123abc1from1-3576@19
> 2.168.10.55
> >
> > Call-ID: 1-3576@xxxxxxxxxxxxx
> >
> > CSeq: 1 INVITE
> >
> > Subject: Performance Test
> >
> > Content-Type: application/sdp
> >
> > Content-Length: 138
> >
> >
> >
> > v=0
> >
> > o=user1 53655765 2353687637 IN IP4 192.168.10.55
> >
> > s=-
> >
> > c=IN IP4 192.168.10.55
> >
> > t=0 0
> >
> > m=audio 10008 RTP/AVP 0
> >
> > a=rtpmap:0 PCMU/8000
> >
> >
> >
> > DEBUG | 20060515-144250.386 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | Transport.cxx:210 | Adding message to tx buffer
to:
> [ V4
> > 192.168.10.55:5070 UDP target domain=192.168.10.55 received on:
> Transport: [
> > V4 0.0.0.0:5060 UDP target domain=unspecified connectionId=0 ]
> > connectionId=0 ]
> >
> > DEBUG | 20060515-144250.386 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | UdpTransport.cxx:56 | Sent: INVITE
> > sip:1111400000@xxxxxxxxxxxxx:5070 SIP/2.0
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5060;branch=z9hG4bK-d87543-f0a0343925a30f66-1--d87543-;rpo
> rt
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5062;branch=z9hG4bK-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx;r
> port=5062
> >
> > Max-Forwards: 70
> >
> > Contact: <sip:3128652501@xxxxxxxxxxxxx:5062>
> >
> > To: <sip:1111400000@xxxxxxxxxxxxx:5060>
> >
> > From:
> >
>
"3128652501"<sip:3128652501@xxxxxxxxxxxxx:5062>;tag=123abc1from1-3576@19
> 2.168.10.55
> >
> > Call-ID: 1-3576@xxxxxxxxxxxxx
> >
> > CSeq: 1 INVITE
> >
> > Subject: Performance Test
> >
> > Content-Type: application/sdp
> >
> > Content-Length: 138
> >
> >
> >
> > v=0
> >
> > o=user1 53655765 2353687637 IN IP4 192.168.10.55
> >
> > s=-
> >
> > c=IN IP4 192.168.10.55
> >
> > t=0 0
> >
> > m=audio 10008 RTP/AVP 0
> >
> > a=rtpmap:0 PCMU/8000
> >
> >
> >
> > DEBUG | 20060515-144250.388 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | UdpTransport.cxx:57 | Sending message on udp.
> >
> > DEBUG | 20060515-144250.601 | mbaj-dev | sipdirector |
RESIP:TRANSPORT
> |
> > 3556 | 29871024 | Transport.cxx:259 | incoming from: [ V4
> 192.168.10.55:5070
> > UDP target domain=unspecified received on: Transport: [ V4
> 0.0.0.0:5060 UDP
> > target domain=unspecified connectionId=0 ] connectionId=0 ]
> >
> > DEBUG | 20060515-144250.618 | mbaj-dev | sipdirector | RESIP:DNS |
> 3556 |
> > 29871024 | DnsResult.cxx:175 | Whitelisting 192.168.10.55(1):
> 192.168.10.55
> >
> > DEBUG | 20060515-144250.618 | mbaj-dev | sipdirector | RESIP:DNS |
> 3556 |
> > 29871024 | dns/RRVip.cxx:129 | updating an existing vip:
192.168.10.55
> with
> > 192.168.10.55
> >
> > DEBUG | 20060515-144250.619 | mbaj-dev | sipdirector |
> RESIP:TRANSACTION |
> > 3556 | 29871024 | TransactionState.cxx:1623 | Send to TU: TU:
> SipDirector
> > size=0 SIP/2.0 100 Trying
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5060;branch=z9hG4bK-d87543-f0a0343925a30f66-1--d87543-;rpo
> rt
> >
> > Via: SIP/2.0/UDP
> >
>
192.168.10.55:5062;branch=z9hG4bK-1-4invite1-3576@xxxxxxxxxxxxxxxxxxxx;r
> port=5062
> >
> > Contact: <sip:192.168.10.55:5070;transport=UDP>
> >
> > To: <sip:1111400000@xxxxxxxxxxxxx:5060>;tag=23-1-3576@xxxxxxxxxxxxx
> >
> > From:
> >
>
"3128652501"<sip:3128652501@xxxxxxxxxxxxx:5062>;tag=123abc1from1-3576@19
> 2.168.10.55
> >
> > Call-ID: 1-3576@xxxxxxxxxxxxx
> >
> > CSeq: 1 INVITE
> >
> > Content-Length: 0
> >
> >
> >
> >
> > ________________________________
> >
> >
> > From: Scott Godin [mailto:slgodin@xxxxxxxxxxxx]
> > Sent: Thursday, May 11, 2006 3:15 PM
> > To: Michael Baj; resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> > Subject: RE: [reSIProcate] Sending 100 trying
> >
> >
> >
> > The stack automatically sends 100's if the application does not send
> > anything after 80ms. So if you are not seeing a 100 it is likely
> because
> > there is another message sent within 80ms.
> >
> >
> >
> >
> > ________________________________
> >
> >
> > From: resiprocate-devel-bounces@xxxxxxxxxxxxxxxxxxx
> > [mailto:resiprocate-devel-bounces@xxxxxxxxxxxxxxxxxxx] On
> > Behalf Of Michael Baj
> > Sent: Thursday, May 11, 2006 2:53 PM
> > To: resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> > Subject: [reSIProcate] Sending 100 trying
> >
> >
> >
> > Greetings,
> >
> >
> >
> > I'm trying to get my forwarding proxy to send a 100 trying message
on
> a new
> > INVITE. Is there a way to configure the stack to send 100 trying on
> new
> > INVITES? (I am not using DUM). I noticed however, that my proxy
will
> send
> > 100 trying on re-INVITEs. I've looked through the repro code and I
> was
> > unable to locate where and if a 100 trying was being generated. I
> noticed
> > that they trap 100 tryings from being forwarded, which is what I do
as
> well.
> >
> >
> >
> > What is the best way to accomplish what I am trying to achieve?
> >
> >
> >
> > Thanks in advance!
> >
> > Michael Baj
> >
> > _______________________________________________
> > resiprocate-devel mailing list
> > resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> > https://list.sipfoundry.org/mailman/listinfo/resiprocate-devel
> >
> >
> _______________________________________________
> resiprocate-devel mailing list
> resiprocate-devel@xxxxxxxxxxxxxxxxxxx
> https://list.sipfoundry.org/mailman/listinfo/resiprocate-devel