® ibm software group © 2007 ibm corporation introduction to sip in websphere erik burckart...
TRANSCRIPT
®
IBM Software Group
© 2007 IBM Corporation
Introduction to SIP in WebSphere
Erik Burckart
WebSphere Architect
IBM Software Group | WebSphere software
2
What is SIP?
Session Initiation Protocol Negotiate a session between two users or services, often utilizing a different
protocol.
Often used for peer to peer models.
Control protocol for many types of new communications Voice over IP (VoIP)
Instant Messaging (IM)
Pivotal protocol in building the next generation telecommunications networks
IBM Software Group | WebSphere software
3
Sarah dials Todd
Trying
Ringing
OK
ACK
Telephone Network
INVITE Todd
Todd picks up
Hello Sarah?
Hi Todd!
How does SIP work?
IBM Software Group | WebSphere software
4
More on SIP… A SIP URL looks like an email address
SIP:[email protected] SIP:[email protected];user=phone
TEL URLs are also used TEL:+1-919-555-1234
Since SIP is used to initiate another session, the popular protocol used to describe that session is called Session Description Protocol (SDP, defined in RFC 2327
Helpful terminology… A Dialog is a peer to peer relationship between
two user agents (SIP nodes) A User Agent Client (UAC) creates a request or
dialog A User Agent Server (UAS) handles a request or
dialog A Back to Back User Agent (B2BUA) is
UAS/UAC combination that handles completes the incoming call and creates another identical one.
A proxy is a stateful server which forwards on the request to another user agent to handle.
IBM Software Group | WebSphere software
5
Proxy
server.telco2.com
Proxy
proxy.telco1.comUser Agent
User Agent
INVITEINVITE
INVITE100 TRYING
100 TRYING
180 RINGING
180 RINGING
180 RINGING 200 OK200 OK
200 OK
ACK
200 OK
BYE
Media Session
IBM Software Group | WebSphere software
6
Sarah dials Todd
SIP/2.0 180 RingingRoute: <sip:s1.telco.com>From: Sarah <sip:[email protected]>To: Todd <sip:[email protected]>Call-ID: abc123CSeq: 1 INVITEContact: <sip:[email protected]>
SIP/2.0 200 OKRoute: <sip:s1.telco.com>From: Sarah <sip:[email protected]>To: Todd <sip:[email protected]>Call-ID: abc123CSeq: 1 INVITEContact: <sip:[email protected]>
ACK sip:[email protected] SIP/2.0Route: <sip:s1.telco.com>From: Sarah <sip:[email protected]>To: Todd <sip:[email protected]>Call-ID: abc123CSeq: 1 ACK
Telephone Network
INVITE sip:[email protected] SIP/2.0Route: <sip:s1.telco.com>From: Sarah <sip:[email protected]>To: Todd <sip:[email protected]>Call-ID: abc123CSeq: 1 INVITEContact: <sip:[email protected]>
Todd picks up
Hello Sarah?
Hi Todd!
More in depth details…
Negotiated Media Session
IBM Software Group | WebSphere software
7
What can I do with SIP?
Utilize SIP environments VoIP IM IPTV Audio/Video conferencing. Next generation Telco networks.
Embed intelligent communications in applications Improve Business Productivity
Click to call, IM Manage calls on the web
– Caller ID information
– Three way calling, voicemail, etc. Integrate with Business Processes
Automatically generated phone calls in a workflow.
IBM Software Group | WebSphere software
8
Examples of Other Potential Applications Business Conferencing
Mobile Conferencing
Virtual Receptionist
Prepaid Calling Cards
Push to Talk over Cellular (PoC)
Voice with Push to See
Voice with Push to Video
Voice with push of Media Mapping services
Converged mobility WiFi to GSM roaming
White Boarding (sharing)
Field Force Efficiency
Field Force Automation
Fleet Management & Logistics
Multimedia messaging with email, fax, voice mail, video mail, IM notification
IM with multimedia
Presence based applications
Interactive Gaming
Text, Picture and Voice Messaging
Subscription Media Push
Video on demand to mobile phone
Personalized call tones
Inbound call screening
Friends & Family Tracking
Security/Medical Monitoring
IBM Software Group | WebSphere software
9
Why IBM?
IBM’s vision is that intelligent communications can be embedded in all applications.
IBM has been utilizing SIP since 2000.
WebSphere Application Server is the first vendor to include SIP in their base Java EE environment, allowing all applications to utilize SIP.
IBM has many products utilizing SIP WebSphere Application Server WebSphere Presence Server (with Group List management) WebSphere IP Multimedia Subsystem Connectors WebSphere Telecom Web Services Server Lotus Sametime Gateway WebSphere Voice Server WebSphere Voice Response More to come…
IBM Software Group | WebSphere software
10
WebSphere SIP
SIP Servlet 1.0 API JSR 116
Built into the Servlet container that also hosts Portlets and HTTP Servlets.
IBM Extensions to SIP and HTTP session to provide fully converged functionality.
SIP Servlet tooling Wizards
Graphical Deployment Descriptor Editors
IBM Software Group | WebSphere software
11
WebSphere Proxy with SIP
High availability that understands applications which include SIP and HTTP.
Converged Proxy server HTTP Reverse Proxy
Stateless SIP Proxy
Routes messages to keep SIP and HTTP Sessions in a single Application Session together.
IBM Software Group | WebSphere software
12
SIP Servlet 1.0 vs HTTP Servlets Asynchronous instead of synchronous.
Servlet has methods for the requests and responses separately.
Multiple servlets can act on a single message
Stateful proxying APIs.
Application can be UAC, UAS, B2BUA, or Proxy.
Provides SipFactory per application for creating requests, sessions, etc.
SipSession and SipApplicationSession
IBM provides useful extensions to the specifications
doGetdoPostdoPut
doHeaddoDeletedoTrace
doOptions
HTTP Servlet
doInvitedoAck
doOptionsdoBye
doCanceldoRegister
doSubscrbedoNotify
doMessagedoInfo
doPrack
SIP Servletrequests
doProvisionalResponsedoSuccessResponsedoRedirectResponse
doErrorResponse
SIP Servlet responses
HttpSession SipSession
SipApplicationSession
IBMSession
IBMApplicationSession
extends
extends
containscontains
references
references
IBM Software Group | WebSphere software
13
SIP Servlet 1.0 API – JSR 116
destroy()
service()
init()
doInvite() doAck()
doOptions() doCancel()
doRegister() doPrack() doInfo()
doNotify() doMessage() doSubscribe()
doProvisionalResponse() doSuccessResponse()
doErrorResponse() doRedirectResponse()
doResponse()
doRequest()
servlet
Create Request()
Create Response()
SIP Message
Client SIP Container SIP Servlet Methods
RulesSIP Message
IBM Software Group | WebSphere software
14
SIP Servlet 1.1 API – JSR 289
Application Router functionality Allows the Deployer to add functionality to dynamically
select which Servlets will be executed.
Spans multiple applications and there will be one per server.
Better support for convergence Session convergence like the WebSphere 6.1 model.
More flexible ways to get to the SipFactory within an application.
Alignment with Java EE 5 Alignment with Servlet 2.5 specification
Annotations support
Utilizes JSR 250 and the Servlet 2.5 specification
Adds Type level annotations like @SipServlet.
Resource injection where appropriate, like accessing the SipFactory
Application Router S
IP A
pp
licat
ion
SIP Servlet API
WebSphere Servlet Container
SIP
Ap
plic
atio
n
SIP
Ap
plic
atio
n
SIP
Ap
plic
atio
n
SIP HTTP
IBM Software Group | WebSphere software
15
Example: Caller ID in a web page
Include information about incoming callers on existing Portals. Could include looking up customer records, LDAP, etc.
Works with SIP network, but does not require SIP phones.
SIP Servlet
JMS Topic HTTP Servlet
IP PBXPSTN
SIP Proxy
Initiate Call
Publish call info
Subscribe to a topic Poll the server for caller ID
Send caller ID
IBM Software Group | WebSphere software
16
Example: Click to call in a webpage Make every phone number a clickable link.
Could include call status
Helps efficiency by ensuring phone numbers are not mistyped.
Works with SIP network, but does not require SIP phones.
Another option below is that the HTTP Servlet can look at the information in the SIP Session since they are tied together
SIP Servlet
JMS Topic HTTP Servlet
IP PBXPSTN
SIP Proxy
Publish call status
Subscribe to a topic Request a call be made
Send status
Make call
Make call
Poll for status
IBM Software Group | WebSphere software
17
Example: Click to call with expert routing Make asking for help a clickable link
Allows an expert to be chosen from a group
Works with SIP network, but does not require SIP phones.
Another option below is that the HTTP Servlet can look at the information in the SIP Session since they are tied together
Group List server
IP PBX SIP Proxy
PSTN
Presence Server
HTTP
SIP
Request Help
Find experts Find availabilityOf experts
Fetch help context
Make call Make call
Acceptcall
Acceptcall
ExpertCustomer
IBM Software Group | WebSphere software
18
Quick code example, click to call
sipFactory =(SipFactory)getServletContext().getAttribute(SipServlet.SIP_FACTORY);
SipURI uriFrom = (SipURI) sipFactory.createURI(from);SipURI uriTo = (SipURI) sipFactory.createURI(to);SipServletRequest req =
sipFactory.createRequest(appSession, "INVITE", uriFrom, uriTo);req.setRequestURI(uriTo);req.send();
SipURI uriFrom = (SipURI) sipFactory.createURI(previousTo);SipURI uriTo = (SipURI) sipFactory.createURI(previousFrom);SipServletRequest req =
sipFactory.createRequest(appSession, "INVITE", uriFrom, uriTo);req.setRequestURI(uriTo);req.send();
Create a call to from the first side. This can be called from the HTTP Servlet by fetching the SipFactory from the Servlet Context.
After the first invitation comes back successful, create a call to the other side with the To and From flipped. This can be added in the doSuccessResponse method of the SipServlet.
IBM Software Group | WebSphere software
19
Questions?
References Introducing SIP Articlehttp://www-128.ibm.com/developerworks/websphere/techjournal/0606_burckart/0606_burckart.html
Developing Converged Applications Articlehttp://www-128.ibm.com/developerworks/websphere/techjournal/0608_burckart/0608_burckart.html
Developing SIP and IP Multimedia Subsystem Applications Redbookhttp://www.redbooks.ibm.com/redbooks.nsf/e9abd4a2a3406a7f852569de005c909f/4ccb6d54f16a5a2f85257134005468db?OpenDocument
WebSphere Application Server SIP documentationhttp://publib.boulder.ibm.com/infocenter/wasinfo/v6r1/index.jsp?topic=/com.ibm.websphere.nd.doc/info/ae/ae/welc6tech_sip_links.html
IBM Software Group | WebSphere software
21
Architecture Converged Container
Seamless integration between JSR 116 SIP Servlets and HTTP Servlets or Portlets. Built on proven WebSphere technology.
Converged Proxy Ensures single point of session affinity management at the application session level, across
HTTP and SIP Provides high availability without expensive hardware.
Servlet ContainerServlets, SIP Servlets, Portlets
Proxy ServerStateless SIP Proxy and HTTP reverse proxy
IBM Software Group | WebSphere software
22
Specifications – What WAS SIP SupportsBody Number Title
JCP JSR 116 SIP Servlet 1.0
IETF RFC 2543 SIP: Session Initiation Protocol 1.0
IETF RFC 3261 SIP: Session Initiation Protocol 2.0
IETF RFC 3262 Reliability of Provisional Responses in SIP. (PRACK Support)
IETF RFC 3263 Locating SIP Servers
IETF RFC 3265 SIP Specific Event Notification
IETF RFC 3326 The Reason Header Field for SIP
IETF RFC 3515 SIP REFER Method.
IETF RFC 3824 Using E.164 numbers with SIP
IETF RFC 3903 SIP extension for Event State Publication
IBM Software Group | WebSphere software
23
Specifications – Applications on WAS.
Many SIP related RFCs can be supported by the applications written on WAS SIP.
2848, 2976, 3050, 3087, 3264, 3266, 3312, 3313, 3319, 3327, 3372, 3398, 3428, 3455, 3578, 3603, 3608, 3665, 3666, 3680, 3725, 3840, 3842, 3856, 3857, 3959, 3960, 3976, 4032, 4092, 4117, 4235, 4240, 4353, 4354, 4411, 4457, 4458, 4483, 4497, 4508
IBM Software Group | WebSphere software
24
Performance Monitoring Available in WAS 6.1
# of active SIP application sessions for the whole container
# of active SIP sessions for the whole container
# of active SIP sessions / application
# of active SIP Application Sessions per application
# of SIP transactions / sec
Average number of messages per second handled by the container and calculated over a configurable period.
# of new SIP Application sessions / sec
Call arrival rate - Average number of new application sessions, per second, calculated over a configurable period.
Number of messages, of each type, coming in and out of each application
Some others