[Freeswitch-users] att_xfer application
Csaba Zelei
csaba.zelei at gmail.com
Wed May 14 03:22:57 PDT 2008
Hi,
Currently I need to set up attended transfer to phones which dont have
any support to it.
So, made a simple extension in features.xml which read the number and
supply it to att_xfer app:
<extension name="att_xfer">
<condition field="destination_number" expression="^att_xfer$">
<action application="read" data="3 4 sounds/mellekek.wav
attxfer_callthis 30000 #"/>
<action application="att_xfer"
data="sofia/default/${attxfer_callthis}"/>
</condition>
</extension>
then bind it to dtmf 3 in default.xml Local Extension with:
<anti-action application="bind_meta_app" data="3 a a
execute_extension::att_xfer XML features"/>
I can activate this feautre, it's hold the bleg and call the 3rd party,
but when I try to make the transfer with dtmf 0 than it hangup all legs.
For me it's look like that FS hangup the channels than try to bridge them.
Here is the console log:
freeswitch at devil4> show channels
API CALL [show(channels)] output:
uuid,created,created_epoch,name,state,cid_name,cid_num,ip_addr,dest,application,application_data,dialplan,context,read_codec,read_rate,write_codec,write_rate
19112de8-2197-11dd-ba14-5dc4d1b7fe8e,2008-05-14
11:21:13,1210756873,sofia/default/anonymous at localhost,CS_EXECUTE,1003,1003,192.168.1.192,1001,att_xfer,sofia/default/1000,XML,default,PCMA,8000,PCMA,8000
193e7bf4-2197-11dd-ba14-5dc4d1b7fe8e,2008-05-14
11:21:13,1210756873,sofia/default/1001,CS_EXCHANGE_MEDIA,1003,1003,192.168.1.192,1001,playback,local_stream://moh,XML,default,PCMA,8000,PCMA,8000
1e67e516-2197-11dd-ba14-5dc4d1b7fe8e,2008-05-14
11:21:22,1210756882,sofia/default/1000,CS_EXCHANGE_MEDIA,1003,1003,192.168.1.192,1000,,,XML,default,PCMA,8000,PCMA,8000
3 total.
freeswitch at devil4> 2008-05-14 11:21:40 [DEBUG] mod_dptools.c:1344
xfer_on_dtmf() sofia/default/1000 State Change CS_EXCHANGE_MEDIA ->
CS_EXECUTE
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:671
switch_core_session_signal_state_change() Kill sofia/default/1000 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:193
audio_bridge_thread() sofia/default/anonymous at localhost ended call via DTMF
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:194
audio_bridge_thread() Kill sofia/default/1000 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:383
switch_core_session_receive_message() Kill
sofia/default/anonymous at localhost [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:344
audio_bridge_thread() Kill sofia/default/1000 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:347
audio_bridge_thread() BRIDGE THREAD DONE [sofia/default/anonymous at localhost]
2008-05-14 11:21:40 [NOTICE] switch_ivr_bridge.c:802
switch_ivr_multi_threaded_bridge() Hangup
sofia/default/anonymous at localhost [CS_EXECUTE] [UNALLOCATED]
2008-05-14 11:21:40 [DEBUG] switch_channel.c:1355
switch_channel_perform_hangup() Kill sofia/default/anonymous at localhost
[KILL]
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:671
switch_core_session_signal_state_change() Kill
sofia/default/anonymous at localhost [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:383
switch_core_session_receive_message() Kill sofia/default/1000 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:344
audio_bridge_thread() Kill sofia/default/anonymous at localhost [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:347
audio_bridge_thread() BRIDGE THREAD DONE [sofia/default/1000]
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:431
switch_core_session_run() (sofia/default/1000) State EXCHANGE_MEDIA
going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:364
switch_core_session_run() sofia/default/1000 Running State Change CS_EXECUTE
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:428
switch_core_session_run() (sofia/default/1000) State EXECUTE
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:156 sofia_on_execute()
sofia/default/1000 SOFIA EXECUTE
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:128
switch_core_standard_on_execute() Standard EXECUTE
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:139
switch_core_standard_on_execute() sofia/default/1000 Execute
three_way(19112de8-2197-11dd-ba14-5dc4d1b7fe8e)
2008-05-14 11:21:40 [DEBUG] switch_core_media_bug.c:227
switch_core_media_bug_add() Attaching BUG to
sofia/default/anonymous at localhost
2008-05-14 11:21:40 [DEBUG] switch_core_media_bug.c:312
switch_core_media_bug_close() Removing BUG from
sofia/default/anonymous at localhost
2008-05-14 11:21:40 [NOTICE] switch_core_state_machine.c:156
switch_core_standard_on_execute() Hangup sofia/default/1000 [CS_EXECUTE]
[NORMAL_CLEARING]
2008-05-14 11:21:40 [DEBUG] switch_channel.c:1355
switch_channel_perform_hangup() Kill sofia/default/1000 [KILL]
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:671
switch_core_session_signal_state_change() Kill sofia/default/1000 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:428
switch_core_session_run() (sofia/default/1000) State EXECUTE going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:364
switch_core_session_run() sofia/default/1000 Running State Change CS_HANGUP
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/1000) State HANGUP
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:264 sofia_on_hangup() Channel
sofia/default/1000 hanging up, cause: NORMAL_CLEARING
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:296 sofia_on_hangup() Sending
BYE to sofia/default/1000
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:46
switch_core_standard_on_hangup() Standard HANGUP sofia/default/1000,
cause: NORMAL_CLEARING
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/1000) State HANGUP going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:731
switch_core_session_thread() Session 5 (sofia/default/1000) Locked,
Waiting on external entities
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:749
switch_core_session_thread() Session 5 (sofia/default/1000) Ended
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:751
switch_core_session_thread() Close Channel sofia/default/1000 [CS_HANGUP]
2008-05-14 11:21:40 [DEBUG] switch_ivr_play_say.c:1130
switch_ivr_play_file() done playing file
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:383
switch_core_session_receive_message() Kill sofia/default/1001 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:160
audio_bridge_thread() Kill sofia/default/anonymous at localhost [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:383
switch_core_session_receive_message() Kill sofia/default/1001 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:344
audio_bridge_thread() Kill sofia/default/anonymous at localhost [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:347
audio_bridge_thread() BRIDGE THREAD DONE [sofia/default/1001]
2008-05-14 11:21:40 [NOTICE] switch_ivr_bridge.c:374
audio_bridge_on_exchange_media() Hangup sofia/default/1001
[CS_EXCHANGE_MEDIA] [NORMAL_CLEARING]
2008-05-14 11:21:40 [DEBUG] switch_channel.c:1355
switch_channel_perform_hangup() Kill sofia/default/1001 [KILL]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:919
switch_ivr_uuid_bridge() originator uuid
1e67e516-2197-11dd-ba14-5dc4d1b7fe8e is not present
2008-05-14 11:21:40 [DEBUG] mod_dptools.c:1371 hanguphook()
Hangup Command uuid_bridge(1e67e516-2197-11dd-ba14-5dc4d1b7fe8e
19112de8-2197-11dd-ba14-5dc4d1b7fe8e):
-ERR Invalid uuid
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:671
switch_core_session_signal_state_change() Kill sofia/default/1001 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:431
switch_core_session_run() (sofia/default/1001) State EXCHANGE_MEDIA
going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:364
switch_core_session_run() sofia/default/1001 Running State Change CS_HANGUP
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/1001) State HANGUP
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:264 sofia_on_hangup() Channel
sofia/default/1001 hanging up, cause: NORMAL_CLEARING
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:296 sofia_on_hangup() Sending
BYE to sofia/default/1001
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:46
switch_core_standard_on_hangup() Standard HANGUP sofia/default/1001,
cause: NORMAL_CLEARING
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/1001) State HANGUP going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:731
switch_core_session_thread() Session 4 (sofia/default/1001) Locked,
Waiting on external entities
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:160
audio_bridge_thread() Kill sofia/default/1001 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:275
audio_bridge_thread() read: sofia/default/anonymous at localhost Bad
Frame.... Bubye!
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:344
audio_bridge_thread() Kill sofia/default/1001 [BREAK]
2008-05-14 11:21:40 [DEBUG] switch_ivr_bridge.c:347
audio_bridge_thread() BRIDGE THREAD DONE [sofia/default/anonymous at localhost]
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:428
switch_core_session_run() (sofia/default/anonymous at localhost) State
EXECUTE going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:364
switch_core_session_run() sofia/default/anonymous at localhost Running
State Change CS_HANGUP
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/anonymous at localhost) State HANGUP
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:264 sofia_on_hangup() Channel
sofia/default/anonymous at localhost hanging up, cause: UNALLOCATED
2008-05-14 11:21:40 [DEBUG] mod_sofia.c:296 sofia_on_hangup() Sending
BYE to sofia/default/anonymous at localhost
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:46
switch_core_standard_on_hangup() Standard HANGUP
sofia/default/anonymous at localhost, cause: UNALLOCATED
2008-05-14 11:21:40 [DEBUG] switch_core_state_machine.c:392
switch_core_session_run() (sofia/default/anonymous at localhost) State
HANGUP going to sleep
2008-05-14 11:21:40 [DEBUG] switch_core_session.c:731
switch_core_session_thread() Session 3
(sofia/default/anonymous at localhost) Locked, Waiting on external entities
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:749
switch_core_session_thread() Session 3
(sofia/default/anonymous at localhost) Ended
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:751
switch_core_session_thread() Close Channel
sofia/default/anonymous at localhost [CS_HANGUP]
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:749
switch_core_session_thread() Session 4 (sofia/default/1001) Ended
2008-05-14 11:21:40 [NOTICE] switch_core_session.c:751
switch_core_session_thread() Close Channel sofia/default/100
My question is if its a bug or I did something wrong?
I used the lastest trunk on Ubuntu linux.
Thanks,
Csaba
More information about the FreeSWITCH-users
mailing list