Dialogic Global Call IP Benutzerhandbuch

Seite von 604
for user persistence. Second, a default transport protocol setting of TCP or a “;transport=tcp” 
parameter in the Request-URI header field is not sufficient to force TCP for a BYE request. 
Instead, it is necessary to also set “;transport=tcp” in the Contact URI header field.
Due to network conditions, in certain instances a 1xx Informational Response or an ACK response 
may be lost and the SIP standards specify that these messages are not re-transmitted. Only in 
instances where the SIP protocol provides for retries of the encompassing transaction will the call 
control library be able to generate proper termination events to the application when a response is 
lost. Applications should be written to handle cases of missing completion events that may be 
caused by missing response messages. 
4.12
Handling SIP Transport Failures
The Global Call SIP implementation provides facilities to retry a SIP request when a transport 
failure occurs as well as notifying the application of the failure. The retry logic used by the SIP 
stack is determined by the value that is set for the E_SIP_RequestRetry field in the 
 configuration structure that is used when the virtual board is started. The default 
configuration enables all allowable retries. 
The following code snippet illustrates the general procedure for setting up the IP_VIRTBOARD 
structure to specify non-default request retry behavior. This specific example disables request 
retries following transport failure. Note that all data structure fields that are not explicitly set are 
assumed to contain their default values as configured by the 
 function.
#include "gclib.h"
..
..
#define BOARDS_NUM 1
..
..
/* initialize start parameters */
IPCCLIB_START_DATA cclibStartData;
memset(&cclibStartData,0,sizeof(IPCCLIB_START_DATA));
IP_VIRTBOARD virtBoards[BOARDS_NUM];
memset(virtBoards,0,sizeof(IP_VIRTBOARD)*BOARDS_NUM);
/* initialize start data */
INIT_IPCCLIB_START_DATA(&cclibStartData, BOARDS_NUM, virtBoards);
/* initialize virtual board */
INIT_IP_VIRTBOARD(&virtBoards[0]);
// Enable SIP Message Info to allow transport selection for individual requests
virtBoards[0].ip_sip_msginfo_mask = IP_SIP_MSGINFO_ENABLE;
//enable TCP for individual requests
virtBoards[0].E_SIP_tcpenabled = ENUM_Enabled;
virtBoards[0].E_Persistence = ENUM_PERSISTENCE_TRANSACT_USER;
//disable SIP request retry
virtboard[0].E_SIP_RequestRetry = ENUM_REQUEST_RETRY_NONE
Features that are enabled or configured via the IP_VIRTBOARD structure cannot be disabled or 
reconfigured once the library has been started. All items set in this data structure take effect when 
the 
 function is called and remain in effect until 
 is called when the 
application exits.