[asterisk-commits] mmichelson: branch group/CCSS r217330 - /team/group/CCSS/main/ccss.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Sep 8 18:30:08 CDT 2009


Author: mmichelson
Date: Tue Sep  8 18:30:07 2009
New Revision: 217330

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=217330
Log:
Flesh out plans for the match_agent callback a bit more.

I think it may be quittin' time for today.


Modified:
    team/group/CCSS/main/ccss.c

Modified: team/group/CCSS/main/ccss.c
URL: http://svn.asterisk.org/svn-view/asterisk/team/group/CCSS/main/ccss.c?view=diff&rev=217330&r1=217329&r2=217330
==============================================================================
--- team/group/CCSS/main/ccss.c (original)
+++ team/group/CCSS/main/ccss.c Tue Sep  8 18:30:07 2009
@@ -492,6 +492,34 @@
  * callback instead. This way I'll know the context in which
  * it is being used, because the circumstances strongly dictate
  * what data should be ignored and what should not be.
+ *
+ * Let's be a bit more specific about this, shall we? There are
+ * three places where this is used, so let's consider each.
+ *
+ * 1) When the time comes to create an instance of the core, 
+ * kill_duplicate_offers is used to destroy any core_instances
+ * which have the same agent interface. The key here is that
+ * we must only examine core_instances which have a NULL
+ * monitor pointer. Those are the ones for which CC has been
+ * offered, but for which the offer has not been accepted.
+ *
+ * Now, when a generic agent is in use, the search may be
+ * expanded to include core_instances with non-NULL monitor
+ * pointers. This doesn't mean that we will kill the pre-
+ * existing request, but it does mean that we will cease
+ * creation of the core_instance.
+ *
+ * 2) When CallCompletionRequest is called, we need to search
+ * through the agents for a specific caller. This application
+ * only applies to core_instances with a NULL monitor pointer,
+ * so this is similar.
+ *
+ * 3) When CallCompletionCancel is called, we once again have
+ * to search the container for a specific caller. In this situation,
+ * though, we only care about core_instances with a non-NULL
+ * monitor pointer.
+ *
+ * A bitfield should do the job nicely.
  */
 static int match_agent(void *obj, void *arg, int flags)
 {




More information about the asterisk-commits mailing list