On Mon, Feb 9, 2009 at 10:19 AM, Gang Liu <gangban.lau at gmail.com> wrote: > Hi benny, > I am finding a way to save pjsip dialog information to external > and restore dialogs if needed. > Like below: > > pj_status_t pjsip_dlg_store_connected(pjsip_dialog *dlg, char * > buf, int * buf_size) > copies all parameters from a given dialog to a given buffer. This > buffer should be supplied when restoring the dialog. > > pj_status_t pjsip_dlg_restore_connected(pjsip_user_agent *ua, char > * buf, int buf_size, pjsip_dialog **p_dlg) > restores all parameters from a given buffer. The dialog will > assume the connected state. > > Could you give me some guideline to implement this? It will be > great to add HA feature into pjsip stack when using UDP transport. > > I think it's quite tedious to add HA (I'm not saying it can't be done). Not only the dialog, you also need to store/restore the invite session as well. Then propagate the API all the way up to application. Alternatively, have you considered other approach, such as using INVITE+Replaces? An entity would monitor the state of the HA agents (saving the key dialog properties such as Call-Id and tags), and when it detects an agent is down, it transfer the call (using INVITE+Replaces) to another agent. cheers Benny -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090210/f0e76ae3/attachment.html>