+

Search Tips   |   Advanced Search

Runtime considerations for SIP application developers


You should consider certain product runtime behaviors when you are writing Session Initiation Protocol (SIP) applications.

 

Container may accept non-SIP URI schemes

The SIP container will not reject a message if it doesn't recognize the scheme in the request Uniform Resource Indicator (URI) because the container cannot know which URI schemes are supported by the applications. SIP elements may support a request URI with a scheme other than sip or sips, for example, the pres: scheme has a particular meaning for presence servers, but the container does not recognize it. It is up to the application to determine whether to accept or to reject a specific scheme. SIP elements may translate non-SIP URIs using any mechanism available, resulting in SIP URIs, SIPS URIs, or other schemes, like the tel URI scheme of RFC 2806 [9].

For transitioning users: When a SIP application sends a request to a SIP URI over TLS in version 6.1, the request URI scheme changes from "sip" to "sips." In version 7.0, the scheme does not change. We can reverse the new behavior in version 7.0 by changing the application code. With a "sips" URI, the behavior remains the same after upgrading from version 6.1 to 7.0. See the information center topic Premigration considerations for more information.trns

 

Directing requests in a multiple-container environment

In a multiple-container environment (SIP proxy plus SIP containers), when the application sends a request intended initially to be sent externally but later received, it should use the host and ports of the front-most load balancing element (either an IP sprayer for multiple SIP proxies, or the SIP proxy if only one exists). If the application uses the host name of a container instead of the front-most element, the request may be lost in the event of a failure.

For example, an application sends an INVITE request to itself, but the request must pass through an external accounting system through a pushed Route header. The application should set the INVITE request's URI to the host and port of the foremost element to ensure that failover occurs. The request will be routed to the accounting system via the pushed Route, and then sent back to the front load balancing element for processing.

 

Invoking session listener events

SipSessionListener and SipApplicationSessionListener events are invoked only if an application requests the corresponding session object. You do this by using in the application the method shown in Methods that invoke session listener events.


Table 1. Methods that invoke session listener events

Event Method
SipSessionListener getSession()
SipApplicationSessionListener getApplicationSession()

 

Session activation and passivation

During normal operation, this product never migrates a session from one server to another. Session migration occurs only as a result of a server failure. Therefore the SipSessionActivationListener method's passivation callback is never invoked. However, the activation callback is invoked when a failure forces session failover to a different server.

 

External resources

If a SIP application performs intensive I/O or accesses an external database, it may be blocked for several milliseconds. If possible, use asynchronous APIs for these resources . Under stress, a blocked SIP application may trigger a Request Timeout or re-transmission.

 

SIP application attributes

Avoid hanging large objects or BLOBs as SIP Session attributes (via SIPSession.setAttribute API). This may damage the overall performance when combined with high availability (HA). The same recommendation applies for SIPApplicationSession.setAttribute. In most cases, the large object can be replaced by several simple or composed strings.



 

Related tasks


Browse all SIP topics
Set up SIP application composition
Develop SIP applications

 

Related


SIP industry standards compliance