Skip to content

Is it possible to resumes the call that was hangedup from UI due to netwok lost. #1125

Description

@anilkotapuri

These are typically directed to the google group.

Handling Temporary Network Loss and Seamless Reconnection in VoIP Application
Problem
In our VoIP application, losing the internet connection causes the call to disconnect immediately on the UI side, which in turn triggers an immediate SIP BYE request. On the receiver's side, the call is hung up after 30 seconds due to our rtp_timeout = 30 configuration, which is the expected behavior for the receiver.

Requirement
Instead of immediately dropping the call on the client UI upon network loss, we want to hold the call screen for 15 seconds (e.g., showing a "reconnecting" state). If the network is restored within this 15-second window, the call should seamlessly resume.

To achieve this, I added a 15-second timeout function on the UI side to hold the call screen. However, after the 15 seconds elapse, the call still hangs up regardless of whether the network was restored or not.

Observation
Normally, a network loss triggers an immediate SIP BYE. With my newly added UI timeout function, it appears the SIP BYE message is being queued or delayed in the background. Right around the 16-second mark, this delayed SIP BYE is finally executed, which terminates the call even if the network connection has recovered.

Question
Is it possible to handle this seamless reconnection scenario (similar to how Google Meet or WhatsApp handles temporary network drops) entirely within the client-side VoIP application? If so, how can I prevent the underlying SIP stack from automatically generating the SIP BYE during this 15-second "reconnecting" window?

Tech Stack:
Asterisk (Dialplan + ARI)
WebRTC
Twilio(carrier)
SIPBuddy
React.js(UI)

Has anyone implemented a similar reconnection/retry mechanism?
Any suggestions or references would be really helpful.

Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions