[SR-Users] Terminate dialogs on [websocket:closed]

mayamatakeshi mayamatakeshi at gmail.com
Wed Feb 10 12:27:00 CET 2016


Hi Daniel,

Yes, that will solve it.
Then when i get the in-dialog INVITE i can revert the lifetime back to the
original value.
Thanks and regards,
Takeshi

On Wed, Feb 10, 2016 at 5:59 PM, Daniel-Constantin Mierla <miconda at gmail.com
> wrote:

> Hello,
>
> perhaps you can just lower the dialog lifetime in the websocket event
> route, then dialog will take care of sending the BYEs, without the need to
> store additional information in hash table.
>
> Cheers,
> Daniel
>
>
> On 09/02/16 23:37, mayamatakeshi wrote:
>
> Hello,
> I am using module websocket and it works very well.
> However I would like to send BYE to the other end if event
> [websocket:closed] happens.
> From the docs I can see websocket module itself doesn't provide for this.
>
> I was considering doing something like this:
>   - use module htable to match $si:$sp to dialogs
>   - use event_route[dialog:start] to insert dialog info to my htable under
> $si:$sp of Websocket side of the call
>   - use event_route[dialog:end] to remove dialog info from htable
>   - use event_route[websocket:closed] to iterate over entries in the
> htable under key $si:$sp and call dlg_get() and dlg_bye().
>
> Obs: in the above, there is a risk of losing some dialogs as insertion in
> htable cannot be done atomically, but I am fine with it as it it not
> expected to happen as WebSocket users would only infrequently generate
> simultaneous calls.
>
> However before going with this, I would like to ask for other possible
> approaches.
>
> Regards,
> Takeshi
>
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing listsr-users at lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>
>
> _______________________________________________
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20160210/9c155d8a/attachment.html>


More information about the sr-users mailing list