Changes between Version 117 and Version 118 of FAQ


Ignore:
Timestamp:
Feb 5, 2013 5:14:28 AM (7 years ago)
Author:
nanang
Comment:

Added DNS failover info

Legend:

Unmodified
Added
Removed
Modified
  • FAQ

    v117 v118  
    10481048If REGISTER is used, then this is becoming less of an issue. PJSUA-LIB will inspect the 200/OK response, check if the IP/port number seen by the server match the IP/port that we use in Contact, and if they're not the same, PJSUA-LIB will update the registration by sending un-REGISTER and new REGISTER with a new Contact. This new Contact then will be used for subsequent requests generated on behalf of the account. 
    10491049 
     1050 
     1051=== How to implement failover with PJSIP? === #dns-failover 
     1052 
     1053Our DNS SRV failover support is only limited to fail-over when TCP (or TLS) connect() fails, which in this case pjsip will automatically retries the next server. But even then, there is no mechanism to flag that a server has been failing, which means that the next request may try the same server again and triggering the fail-over again.  
     1054 
     1055What we've been suggesting is to implement the fail-over mechanism in the application layer. In this case, the application queries the list of available servers either with gethostbyname(), DNS SRV, or by other means. It then specifies which server to use by putting the IP address as proxy parameter (i.e. Route header) in the account config. The mechanism to test the wellness of a server and when to initiate the fail-over is totally controlled by the application. The application can change which server to use by changing the account proxy setting with pjsua_acc_modify().  
    10501056 
    10511057---- 
     
    17091715 
    17101716Antonio F. Cano Damas and Mats Bengtsson have contributed TCL binding for PJSIP, please have a look in the [http://www.pjsip.org/contrib.htm PJSIP Contribution] page. 
    1711