aspose file tools*
The moose likes Servlets and the fly likes Sending an INVITE to my VoIP account by a SIP Servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Sending an INVITE to my VoIP account by a SIP Servlet" Watch "Sending an INVITE to my VoIP account by a SIP Servlet" New topic
Author

Sending an INVITE to my VoIP account by a SIP Servlet

Namitha karupaiya
Ranch Hand

Joined: Mar 10, 2004
Posts: 89
I tried to make an outbound call to an ordinary landline number through my VoIP account by a SIP Servlet, but never been successful.

I tried something similar to the following:

javax.servlet.sip.SipFactory factory=(javax.servlet.sip.SipFactory) this.getServletContext().getAttribute(javax.servlet.sip.SipServlet.SIP_FACTORY);

javax.servlet.sip.SipApplicationSession appSession =factory.createApplicationSession();

to = �sip:land_line_number@my_voip_proxy_server.com�
from=�sip:my_voip_did_number:my_voip_password@ my_voip_proxy_server.com�

javax.servlet.sip.SipServletRequest invite = factory.createRequest(appSession, "INVITE", from, to);

invite.pushRoute(URI of my_voip_outbound_proxy_server.com);

invite.send();

I use Weblogic SIP server. I configured sip.xml, and everything else is correct to my knowledge.

I always get the error message something similar to �Cannot resolve path to my_voip_proxy_server.com�

(Note: When I use SJPhone softphone with my VoIP account details, it simply rings to a landline)

Is the way I incorporating my_voip_outbound_proxy_server correct?

Any help from anyone is greatly appreciated.

Thank you very much.
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

See:
http://www.coderanch.com/t/364899/Servlets/java/Sending-INVITE-VoIP-account-SIP


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Sending an INVITE to my VoIP account by a SIP Servlet