From 33e7b76d1dc8bcd50ad9e121e1c8c8d6081a0a34 Mon Sep 17 00:00:00 2001 From: Matthew Jordan Date: Thu, 8 Aug 2013 14:13:05 +0000 Subject: Hide the Surrogate channels from external consumers; kill Masquerade events This patch does three things: 1. It provides a Surrogate channel technology with a consolidated "implementation detail flag" on the channel technology. This tells consumers of Stasis that the creation of this channel is an implementation detail in Asterisk and can be ignored (if they so choose). This consolidates the conference recorder/announcer flags as well - these flags had no additional meaning beyond "ignore this channel please". 2. It modifies allocation of a channel in two ways: (a) If a channel technology can be determined from the name, we set it directly in the allocation routine. This prevents the initial publication of the message from going out with a NULL channel technology where possible. This lets Stasis consumers get the right channel technology on the first publication. (b) It reorganizes allocation to make use of the 'finalized' property on the channel. This was already used to know that a channel had completely finished its construction in the masquerade routine; now we also use it to know whether or not the setting of certain channel properties is occurring during or post construction. The various set routines were modified accordingly as well. 3. The masquerade event is now dead, Jim. It no longer served any purpose whatsoever - if you perform a call pickup you'll get a Pickup event; if you perform an attended transfer you will still get those events; if you steal a channel to put it elsewhere you'll get the corresponding NewExten or BridgeEnter events. Review: https://reviewboard.asterisk.org/r/2740 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@396392 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- apps/confbridge/conf_chan_announce.c | 2 +- apps/confbridge/conf_chan_record.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'apps/confbridge') diff --git a/apps/confbridge/conf_chan_announce.c b/apps/confbridge/conf_chan_announce.c index 19224254d..df48aed33 100644 --- a/apps/confbridge/conf_chan_announce.c +++ b/apps/confbridge/conf_chan_announce.c @@ -134,7 +134,7 @@ static struct ast_channel_tech announce_tech = { .send_text = ast_unreal_sendtext, .queryoption = ast_unreal_queryoption, .setoption = ast_unreal_setoption, - .properties = AST_CHAN_TP_ANNOUNCER, + .properties = AST_CHAN_TP_INTERNAL, }; struct ast_channel_tech *conf_announce_get_tech(void) diff --git a/apps/confbridge/conf_chan_record.c b/apps/confbridge/conf_chan_record.c index c3f717074..7080d118c 100644 --- a/apps/confbridge/conf_chan_record.c +++ b/apps/confbridge/conf_chan_record.c @@ -86,7 +86,7 @@ static struct ast_channel_tech record_tech = { .call = rec_call, .read = rec_read, .write = rec_write, - .properties = AST_CHAN_TP_RECORDER, + .properties = AST_CHAN_TP_INTERNAL, }; struct ast_channel_tech *conf_record_get_tech(void) -- cgit v1.2.3