Skip to main content

Mobicents SIP servlets server + Sip Communicator = doesn't work?

5 replies [Last post]
bagstone
Offline
Joined: 2008-09-08

Hi everyone,

I've installed the Mobicents SIP servlets server and run a click2call test successfully with Ekiga.
Now I want to do the same with SIP Communicator (because we want a Java open source SIP client).

From \ To sip:testpc@143.106.148.165 sip:desktop@143.106.148.165 sip:laptop@143.106.148.165
sip:testpc@143.106.148.165 call call
sip:desktop@143.106.148.165 call call
sip:laptop@143.106.148.165 call call

All my three computers are registered as you can see (desktop is the one with the Tomcat server).
When I click on one of the call buttons, the first client gets a call message, but then nothing happens - the other client doesn't get an invite. When I try to call directly (by typing sip:testpc@143.106.148.165 from my laptop in the call field in SIP communicator) it's the same, it opens a call window on the calling computer, but the target doesn't get any response.

http://www.nopaste.org/p/atlsneMTl
Server log for click2call between laptop and testpc.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
vralev
Offline
Joined: 2007-04-01

Hi,

This is a problem with SIP communicator. SIP communicator does not handle properly INVITE requests without SDP. Your second SIP client doesn't receive INVITE because the INVITE is sent only after the first client has accepted the first call.

When you call directly the SDP is in the INVITE.

My suggestions is to ping the SIP Communicator guys.

bagstone
Offline
Joined: 2008-09-08

Thanks for your answer...

But even if I call directly, it doesn't work.
http://nopaste.com/p/aacEspxY
(IP .165 is host, .171 target pc but I have to call sip:targetname@serverip, right?)

If I call sip:targetname@targetIP I get a call and can accept it but it gets stuck at "connecting" on calling pc and "incoming call" on target pc...

Did you mean the second thing with "call directly" or what?

vralev
Offline
Joined: 2007-04-01

Yes, I meant the second thing (calling one client from another). The first thing (calling through a proxy) is not supposed to work since the click2call application is not a proxy application. It is straightforward to extend click2call with proxy functionality if you need it.

bagstone
Offline
Joined: 2008-09-08

You mean, the SIP Servlets server can't handle invite requests like these and is just used to connect two clients with the click2call example? Do I get this right?

I thought Mobicents was a complete SIP server and the click2call example was just ONE example how to create a call?

I'm not sure but maybe proxy functionality would solve my problems and issue me the desired results. Problem is: I've got only a few hours left to get Sip Communicator to work, since I'll leave to vacation tomorrow noon. Is there some easy workaround or should I just say "Mobicents SIP Servlets server + SIP Communicator = not working without some modifying"?

We're searching for a SIP server and a SIP client which are both open source, both easy to install and work together just to get an insight into how SIP works. Preferrably Java open source, I have to add...

Message was edited by: bagstone

vralev
Offline
Joined: 2007-04-01

"I thought Mobicents was a complete SIP server and the click2call example was just ONE example how to create a call? " - this is correct

SIP Servlets can handle INVITE (and all other) SIP requests. Now, the applications hosted in the SIP Servlets can be "subscribed" to be called when some initial request arrives. The Click2Call application in particular will not handle INVITE, because it's purpose is to create INVITEs and send them to the phones, not to handle incoming INVITEs. In other words - click2call calls the sip phones, the sip phones never call the click2call application.

Even though the click2call application will not handle INVITEs, it will handle REGISTERs to allow the phones addresses to appear in the table.

Why calling phones through click2call application doesn't work?
If you try to call some other phone through the sip servlets server, the request that arrives at the server will be dispatched to the applications that are subscribed to this request. If no applications are subscribed then the server returns an error. By default there are no applications subscribed for INVITE requests (check this in the application router management tool http://localhost:8080/sip-servlets-management). Once you subscribe your app to INVITEs, you will receive it, but it is still your responsibility to forward this request to the other phone. This is as simple as doing request.getProxy().proxyTo("sip:otherphone@localhost"); in the doInvite() callback.

You should look at the source code of the examples to get a better idea.