RE: SipProvider.addSipListener()

<[email protected]>
Newsgroups gmane.comp.voip.nist-sip
Message-ID <0066AA5B1F5610499032AF6C87B8D5980866B0FF@i2km86-ukdy.domain1.systemhost.net>
What is the reasoning behind 1 sip listener per stack?  Seems that in
other stacks (TCP stacks for example) that I can have different
listeners on different ports and they're independent of each other.  Why
isn't this the case in the SIP stack?

I'm also confused why, in 1.2, there will be 1 sip stack (presumably
over all ip's in a JVM).  I presume this hasn't been implemented in 1.2
yet as I was able to create 2 sip stacks for different IPs (localhost
and external).  If I won't be able to do this in the future, it is
absolutely vital that I be able to specify multiple listeners for a
given stack (specifically for Unit Testing which needs to mimic a sip
phone for example within the same jvm as the Class Under Test (which is
running it's own sip listeners)).  

Thanks for the explanation
Andy Ochsner

-----Original Message-----
From: M. Rangnathan [mailto:[email protected]] 
Sent: Tuesday, February 28, 2006 11:54 AM
To: Ochsner,AM,Andrew,XCB5 R
Cc: [email protected]
Subject: Re: [nist-sip] SipProvider.addSipListener()

Andy,

You can have only one sip listener per stack. You can have multiple 
stacks in v1.1 ( but only one in v1.2 of the spec).


Regards


Ranga


[email protected] wrote:

> Ok so I'm stuck here. I am trying to use SipUnit to test a module that

> also uses nist-sip. Since they are both running on the same IP, it 
> seems that nist-sip reuses the SipStack, which seems fair. However, in

> my module I create a SipProvider and SipUnit also creates a 
> SipProvider. Both need SipListeners attached but I get a 
> TooManyListenersException. These are <different> SipProvider objects, 
> but when it iterates through the SipStack's providers when adding a 
> new listener, it seems to make sure that ALL SipProviders only use the

> same SipListener.
>
> I would have thought that each SipProvider could have it's own 
> SipListener (but only 1).
>
>
> Am I doing something wrong or is there a better approach? Or do I have

> to run my module in a different JVM?
>
> Andy Ochsner
>
> --If you think something's supposed to be difficult, you're less 
> likely to notice if you're doing it wrong.
>
>-----------------------------------------------------------------------
-
>
>_______________________________________________
>nist-sip mailing list
>[email protected]
>http://www-x.antd.nist.gov/mailman/listinfo/nist-sip
>  
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.