4.6 Dialog State Recovery
This section follows the product behavior described in endnote <77>.
The following example shows messages exchanged between the user agent and the proxy server when the proxy detects dialog state loss and communicates this to the user agent, which subsequently recovers the dialog.
The user agent sends a mid-dialog request with the route set from the current dialog state.
-
MESSAGE sip:Alice@contoso.com;gruu;opaque=user:epid:qIIWS2j5AVeD_HxnQdxmlwAA SIP/2.0 Route: <sip:server.contoso.com:5061;transport=tls;opaque=state:F:T:Ci.D1100:Ti.dyHFp3e3J0mXFhCDvmsQ7QAA;lr;ms-route-sig=aag0AbAT3mK4Ga8lsHSyTeZnAETjcRJpFx8YnUbQAA> From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bK94bd Cseq: 3 MESSAGE Supported: Ms-Dialog-Route-Set-Update Content-Length: 27 Alice, are you still there?
The proxy detects that the references to the state information stored in the route set are not valid and that the user agent supports the dialog state recovery procedure as indicated by the Ms-Dialog-Route-Set-Update option tag in the Supported header field. The proxy responds with a 430 Flow Failed response, requesting the user agent to update the dialog state information.
-
SIP/2.0 430 Flow Failed From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bK94bd;ms-received-cid=3540900 Cseq: 3 MESSAGE P-Dialog-Recovery-Action: dialog-route-set-update Content-Length: 0
The user agent sends the correct target refresh request without the route set to recover the dialog state.
-
INVITE sip:Alice@contoso.com;gruu;opaque=user:epid:qIIWS2j5AVeD_HxnQdxmlwAA SIP/2.0 From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bKa8d4 Cseq: 4 INVITE Supported: Ms-Dialog-Route-Set-Update Contact: <sip:Bob@contoso.com;gruu;opaque=user:epid:uVUjrngkI1wHVm3r2esBAAA> Content-Length: 0
The user agent receives the 200 OK response and updates its dialog state with the new route set.
-
SIP/2.0 200 OK RecordRoute: <sip:server.contoso:5061;transport=tls;opaque=state:F:T:Ci.D1200:Ti.dyHFp3e3J0mXFhCDvmsQ7QAA;lr;ms-route-sig=aalzpOt84oODZx4KmWgmgJLf_WGfEsKwh8YnUbQAA> From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bKa8d4;ms-received-cid=3540900 Cseq: 4 INVITE Contact: <sip:Alice@contoso.com;gruu;opaque=user:epid:qIIWS2j5AVeD_HxnQdxmlwAA> Content-Length: 0
The user agent then resends the request with the updated route set.
-
MESSAGE sip:Alice@contoso.com;gruu;opaque=user:epid:qIIWS2j5AVeD_HxnQdxmlwAA SIP/2.0 Route: <sip:server.contoso:5061;transport=tls;opaque=state:F:T:Ci.D1200:Ti.dyHFp3e3J0mXFhCDvmsQ7QAA;lr;ms-route-sig=aalzpOt84oODZx4KmWgmgJLf_WGfEsKwh8YnUbQAA> From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bK97b2 Cseq: 5 MESSAGE Supported: Ms-Dialog-Route-Set-Update Content-Length: 27 Alice, are you still there?
The request gets through and the user agent receives a successful response.
-
SIP/2.0 200 OK From: sip:Bob@contoso.com;epid=02020202;tag=02020202 To: sip:Alice@contoso.com;epid=01010101;tag=01010101 Call-Id: f0ec9c595c1f412ca6b71318beb599bb Via: SIP/2.0/TLS 192.0.2.1:27221;branch=z9hG4bK97b2;ms-received-cid=3540900 Cseq: 5 MESSAGE Content-Length: 0