[reSIProcate] Finding the correct DialogID to get the InviteSession

Kovar, William (Bill) bkovar at avaya.com
Wed May 10 09:46:47 CDT 2006


Hong,
 
Looks like the trick is to store DialogId* into the map, i.e.:
 

std::map<unsigned long refid, DialogId*> the_map;

the_map[refid] = &(ish->getAppDialog()->getDialogID()); 

 
Then the compiler stops complaining about a missing copy constructor....
 
However, I'm concerned about the lifetime of that DialogId*. I intend to
remove it from the map as appropriate, and check it when I get it, i.e.
did->getCallId().size() > 0. 
 
Can I assume that the DialogId exists in DUM as long as the session
exists?? And as a side note, is there a particular callback where I can
put the code to remove the DialogId from the map just before it is
deleted?
 
Thanks!!
 
Bill Kovar
 

  _____  

From: Hong Yu [mailto:hyu at metreos.com] 
Sent: Wednesday, May 10, 2006 10:24 AM
To: Kovar, William (Bill); resiprocate-devel
Subject: RE: [reSIProcate] Finding the correct DialogID to get the
InviteSession



Bill,

 

That's pretty much how I did it. The only difference is that I saved a
string version of the DialogId and I added a parse function to class
DialogId to rebuild it from a string. I'm not sure how others handle
this.

 

Hong Yu

 

  _____  

From: Kovar, William (Bill) [mailto:bkovar at avaya.com] 
Sent: Tuesday, May 09, 2006 5:27 PM
To: resiprocate-devel
Subject: [reSIProcate] Finding the correct DialogID to get the
InviteSession

 

I'm building a multiple UA server that receives 3rd party commands that
contain a Uri and refid.

 

A top layer maps Uri->UA to find the UA. But I can't seem to figure out
what to persist in my UA to find the correct dialog to act on. My UA may
have multiple active sessions.

 

If I map inside the UA as such: 

std::map<unsigned long refid, DialogId> the_map;

and then add to the map 

the_map[refid] = ish->getAppDialog()->getDialogID(); 

and then do:

mdum->findInviteSession(DialogId);

 

Compiler complains about no appropriate copy constructor on
resip::DialogId.

 

Should I modify class DialogId to have a copy constructor or is there
another way around this? Or does the DialogUsageManager have some
goodies for me to use to find the correct session inside one UA.

 

Any alternatives to findInviteSession() ??

 

Any suggestions??

 

Bill Kovar

bkovar at avaya.com

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.resiprocate.org/pipermail/resiprocate-devel/attachments/20060510/b0c9edc0/attachment.htm>


More information about the resiprocate-devel mailing list