VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
adeel.gnome at gmail.com Guest
|
Posted: Wed Aug 27, 2008 1:04 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari |
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Wed Aug 27, 2008 1:15 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org |
|
Back to top |
|
|
adeel.gnome at gmail.com Guest
|
Posted: Wed Aug 27, 2008 1:38 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari |
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Wed Aug 27, 2008 1:46 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Could it be a NAT issue?
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:35 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org |
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Wed Aug 27, 2008 1:46 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Here goes:
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> originate sofia/internal/1001 sofia/internal/1003 (my command)
2008-08-26 23:36:01 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [e11e956a-13dd-de42-b2a1-89733eaaff5d]
2008-08-26 23:36:01 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:08 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:08 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK e11e956a-13dd-de42-b2a1-89733eaaff5d
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> 2008-08-26 23:36:09 [INFO] mod_dialplan_xml.c:222 dialplan_hu
nt() Processing FreeSWITCH->sofia/internal/1003@default
2008-08-26 23:36:10 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:11 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:11 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 5 (sofia/internal/1001) Ended
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
originate sofia/internal/1001 sofia/internal/1003
2008-08-26 23:36:22 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [c4f1a1a2-c608-c642-a672-e97b6933da4b]
2008-08-26 23:36:22 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:27 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:28 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK c4f1a1a2-c608-c642-a672-e97b6933da4b
2008-08-26 23:36:28 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1003@default
2008-08-26 23:36:29 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:30 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:30 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:35 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org |
|
Back to top |
|
|
adeel.gnome at gmail.com Guest
|
Posted: Wed Aug 27, 2008 2:23 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
On Wed, Aug 27, 2008 at 2:38 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Here goes:
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> originate sofia/internal/1001 sofia/internal/1003 (my command)
2008-08-26 23:36:01 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [e11e956a-13dd-de42-b2a1-89733eaaff5d]
2008-08-26 23:36:01 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:08 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:08 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK e11e956a-13dd-de42-b2a1-89733eaaff5d
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> 2008-08-26 23:36:09 [INFO] mod_dialplan_xml.c:222 dialplan_hu
nt() Processing FreeSWITCH->sofia/internal/1003@default
2008-08-26 23:36:10 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:11 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:11 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 5 (sofia/internal/1001) Ended
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
originate sofia/internal/1001 sofia/internal/1003
2008-08-26 23:36:22 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [c4f1a1a2-c608-c642-a672-e97b6933da4b]
2008-08-26 23:36:22 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:27 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:28 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK c4f1a1a2-c608-c642-a672-e97b6933da4b
2008-08-26 23:36:28 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1003@default
2008-08-26 23:36:29 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:30 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:30 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:35 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari |
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Wed Aug 27, 2008 3:03 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Thanks a lot!
it worked - but why?
When I did the same thing through the program it gave me :
at RMIServer.main(RMIServer.java:49)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(Recursi
veTypeParserImpl.java:115)
at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResp
onseParser.java:126)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startEle
ment(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scan
StartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(U
nknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next
(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown So
urce)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Un
known Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.p
arse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStr
eamTransport.java:265)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStre
amTransport.java:216)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorke
r.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at RMIServer.makeACall(RMIServer.java:36)
at RMIServer.main(RMIServer.java:49)
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 12:21 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
On Wed, Aug 27, 2008 at 2:38 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Here goes:
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> originate sofia/internal/1001 sofia/internal/1003 (my command)
2008-08-26 23:36:01 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [e11e956a-13dd-de42-b2a1-89733eaaff5d]
2008-08-26 23:36:01 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:08 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:08 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK e11e956a-13dd-de42-b2a1-89733eaaff5d
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> 2008-08-26 23:36:09 [INFO] mod_dialplan_xml.c:222 dialplan_hu
nt() Processing FreeSWITCH->sofia/internal/1003@default
2008-08-26 23:36:10 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:11 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:11 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 5 (sofia/internal/1001) Ended
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
originate sofia/internal/1001 sofia/internal/1003
2008-08-26 23:36:22 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [c4f1a1a2-c608-c642-a672-e97b6933da4b]
2008-08-26 23:36:22 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:27 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:28 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK c4f1a1a2-c608-c642-a672-e97b6933da4b
2008-08-26 23:36:28 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1003@default
2008-08-26 23:36:29 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:30 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:30 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:35 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org |
|
Back to top |
|
|
adeel.gnome at gmail.com Guest
|
Posted: Wed Aug 27, 2008 3:23 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Show your program. Further, try the example given in here after appropriate modification.
http://wiki.freeswitch.org/wiki/Freeswitch_XML-RPC#Java_Example
On Wed, Aug 27, 2008 at 3:56 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Thanks a lot!
it worked - but why?
When I did the same thing through the program it gave me :
at RMIServer.main(RMIServer.java:49)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(Recursi
veTypeParserImpl.java:115)
at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResp
onseParser.java:126)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startEle
ment(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scan
StartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(U
nknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next
(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown So
urce)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Un
known Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.p
arse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStr
eamTransport.java:265)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStre
amTransport.java:216)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorke
r.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at RMIServer.makeACall(RMIServer.java:36)
at RMIServer.main(RMIServer.java:49)
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 12:21 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
On Wed, Aug 27, 2008 at 2:38 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Here goes:
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> originate sofia/internal/1001 sofia/internal/1003 (my command)
2008-08-26 23:36:01 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [e11e956a-13dd-de42-b2a1-89733eaaff5d]
2008-08-26 23:36:01 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:08 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:08 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK e11e956a-13dd-de42-b2a1-89733eaaff5d
freeswitch@Comp36 ([email]freeswitch@Comp36[/email])> 2008-08-26 23:36:09 [INFO] mod_dialplan_xml.c:222 dialplan_hu
nt() Processing FreeSWITCH->sofia/internal/1003@default
2008-08-26 23:36:10 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:11 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:11 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 5 (sofia/internal/1001) Ended
2008-08-26 23:36:11 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
originate sofia/internal/1001 sofia/internal/1003
2008-08-26 23:36:22 [NOTICE] switch_channel.c:534 switch_channel_set_name() New
Channel sofia/internal/1001 [c4f1a1a2-c608-c642-a672-e97b6933da4b]
2008-08-26 23:36:22 [NOTICE] sofia.c:2183 sofia_handle_sip_i_state() Ring-Ready
sofia/internal/1001!
2008-08-26 23:36:27 [NOTICE] sofia.c:2507 sofia_handle_sip_i_state() Channel [so
fia/internal/1001] has been answered
2008-08-26 23:36:28 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to XML[sofia/internal/1003@default]
API CALL [originate(sofia/internal/1001 sofia/internal/1003)] output:
+OK c4f1a1a2-c608-c642-a672-e97b6933da4b
2008-08-26 23:36:28 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1003@default
2008-08-26 23:36:29 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1003@default]
2008-08-26 23:36:30 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 23:36:30 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 23:36:30 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:35 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Orite. But where is the command? Where is the console output? Don't forget to press F8 on console to enable the debug mode.
On Wed, Aug 27, 2008 at 2:08 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | same result
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 11:03 PM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to issue the same command, what you are issuing via rpc, directly on freeswitch console. And don't forget to enable the debug mode this time. You can enable debug anytime by pressing F8 on freeswitch console.
Cheers.
On Wed, Aug 27, 2008 at 1:41 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Hey Adeel,
Thanks for the help - actually, I was swapping the username and password! shoot me!
Anyways, the code still executed partially. FreeSwitch now says this:
nsfer sofia/internal/1001 to XML[sofia/internal/1002@default]
2008-08-26 22:29:11 [INFO] mod_dialplan_xml.c:222 dialplan_hunt() Processing Fre
eSWITCH->sofia/internal/1002@default
2008-08-26 22:29:12 [NOTICE] switch_ivr.c:1098 switch_ivr_session_transfer() Tra
nsfer sofia/internal/1001 to enum[sofia/internal/1002@default]
2008-08-26 22:29:13 [INFO] switch_core_state_machine.c:114 switch_core_standard_
on_routing() No Route, Aborting
2008-08-26 22:29:13 [NOTICE] switch_core_state_machine.c:115 switch_core_standar
d_on_routing() Hangup sofia/internal/1001 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:807 switch_core_session_threa
d() Session 6 (sofia/internal/1001) Ended
2008-08-26 22:29:13 [NOTICE] switch_core_session.c:809 switch_core_session_threa
d() Close Channel sofia/internal/1001 [CS_HANGUP]
Any idea why this is happening? the destination extension is logged in alright and I can make a successful call to it using the xlite soft phone directly. I tried it out with other destination numbers as well. I am using a LAN IP for my domain.
Regards,
Gayatri Kulkarni
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Tuesday, August 26, 2008 8:34 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try to remove the credentials from the file <freeswitch-installation>/conf/autoload-configs/xmlrpc.conf.xml
and remove the username and password from your code as well. Then try it again.
Just to make sure its working. After that you can revert all back.
Otherwise, you can try the url in your internet browser. It should ask for the credential. By default username=freeswitch and password=works.
Cheers.
On Tue, Aug 26, 2008 at 10:54 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari |
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Tue Sep 02, 2008 6:37 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Hey Adeel,
Remember, originate sofia/internal/1001 &bridge(sofia/internal/1003) had worked the other day?
Well, now it isn't working!
FS is still saying No_ROUTE_DESTINATION
And, it is also giving me a SAXParseException!
You want to have a look at the code?
Here it is:
/**
*
*/
package localcall;
import java.lang.String;
import java.net.*;
import org.apache.xmlrpc.XmlRpcException;
import org.apache.xmlrpc.client.XmlRpcClient;
import org.apache.xmlrpc.client.XmlRpcClientConfigImpl;
/**
* @author Gayatri Kulkarni
*
*/
public class LocalCall {
/**
*
*/
public LocalCall() {
// TODO Auto-generated constructor stub
}
public XmlRpcClientConfigImpl setConfig(){
XmlRpcClientConfigImpl conf = new XmlRpcClientConfigImpl();
String server = "http://192.168.10.36/RPC2";
String uname = "freeswitch";
String pswd = "works";
try {
URL server_url = new URL(server);
conf.setServerURL(server_url);
}
catch (MalformedURLException e){
System.out.println("Cannot generate server URL");
}
conf.setBasicPassword(pswd);
conf.setBasicUserName(uname);
return (conf);
}
public void placeCall(XmlRpcClientConfigImpl conf){
XmlRpcClient rpcClient = new XmlRpcClient();
String api = "freeswitch.api";
rpcClient.setConfig(conf);
Object[] params = new Object[]{ "originate",
"sofia/internal/1001 &bridge(sofia/internal/1002)" };
try {
rpcClient.execute(api, params );
}
catch (XmlRpcException excpn){
System.out.println("Could not execute service. \n");
excpn.printStackTrace();
}
}
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
LocalCall call = new LocalCall();
call.placeCall(call.setConfig());
}
}
I have done load mod_xml_rpc on the CLI of FS.
Thanks a lot,
Regards,
Gayatri Kulkarni
-----
Whenever you find yourself on the side of the majority, it is time to pause and reflect.
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 1:20 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Show your program. Further, try the example given in here after appropriate modification.
http://wiki.freeswitch.org/wiki/Freeswitch_XML-RPC#Java_Example
On Wed, Aug 27, 2008 at 3:56 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Thanks a lot!
it worked - but why?
When I did the same thing through the program it gave me :
at RMIServer.main(RMIServer.java:49)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(Recursi
veTypeParserImpl.java:115)
at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResp
onseParser.java:126)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startEle
ment(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scan
StartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(U
nknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next
(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown So
urce)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Un
known Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.p
arse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStr
eamTransport.java:265)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStre
amTransport.java:216)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorke
r.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at RMIServer.makeACall(RMIServer.java:36)
at RMIServer.main(RMIServer.java:49)
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 12:21 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
|
|
|
Back to top |
|
|
xtpl.gayatri at gmail.com Guest
|
Posted: Tue Sep 02, 2008 7:29 am Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Guys I made a stupid mistake again
guess what - I didn’t specify the port number in the URL !!!
anyways, the code worked
the exception was because I was using an older version of XMLRPC API.
Anyways, Adeel you can modify the Java example on the wiki with this one. I think this one's better than what you already have posted there - if you don’t mind that is!
I don’t mean to offend you.
Thanks a lot anyways!
Regards,
Gayatri Kulkarni
-----
Whenever you find yourself on the side of the majority, it is time to pause and reflect.
From: Gayatri Kulkarni (xtpl.gayatri@gmail.com)
Sent: Tuesday, September 02, 2008 4:29 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Hey Adeel,
Remember, originate sofia/internal/1001 &bridge(sofia/internal/1003) had worked the other day?
Well, now it isn't working!
FS is still saying No_ROUTE_DESTINATION
And, it is also giving me a SAXParseException!
You want to have a look at the code?
Here it is:
/**
*
*/
package localcall;
import java.lang.String;
import java.net.*;
import org.apache.xmlrpc.XmlRpcException;
import org.apache.xmlrpc.client.XmlRpcClient;
import org.apache.xmlrpc.client.XmlRpcClientConfigImpl;
/**
* @author Gayatri Kulkarni
*
*/
public class LocalCall {
/**
*
*/
public LocalCall() {
// TODO Auto-generated constructor stub
}
public XmlRpcClientConfigImpl setConfig(){
XmlRpcClientConfigImpl conf = new XmlRpcClientConfigImpl();
String server = "http://192.168.10.36/RPC2";
String uname = "freeswitch";
String pswd = "works";
try {
URL server_url = new URL(server);
conf.setServerURL(server_url);
}
catch (MalformedURLException e){
System.out.println("Cannot generate server URL");
}
conf.setBasicPassword(pswd);
conf.setBasicUserName(uname);
return (conf);
}
public void placeCall(XmlRpcClientConfigImpl conf){
XmlRpcClient rpcClient = new XmlRpcClient();
String api = "freeswitch.api";
rpcClient.setConfig(conf);
Object[] params = new Object[]{ "originate",
"sofia/internal/1001 &bridge(sofia/internal/1002)" };
try {
rpcClient.execute(api, params );
}
catch (XmlRpcException excpn){
System.out.println("Could not execute service. \n");
excpn.printStackTrace();
}
}
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
LocalCall call = new LocalCall();
call.placeCall(call.setConfig());
}
}
I have done load mod_xml_rpc on the CLI of FS.
Thanks a lot,
Regards,
Gayatri Kulkarni
-----
Whenever you find yourself on the side of the majority, it is time to pause and reflect.
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 1:20 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Show your program. Further, try the example given in here after appropriate modification.
http://wiki.freeswitch.org/wiki/Freeswitch_XML-RPC#Java_Example
On Wed, Aug 27, 2008 at 3:56 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Thanks a lot!
it worked - but why?
When I did the same thing through the program it gave me :
at RMIServer.main(RMIServer.java:49)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(Recursi
veTypeParserImpl.java:115)
at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResp
onseParser.java:126)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startEle
ment(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scan
StartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(U
nknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next
(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown So
urce)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Un
known Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.p
arse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStr
eamTransport.java:265)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStre
amTransport.java:216)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorke
r.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at RMIServer.makeACall(RMIServer.java:36)
at RMIServer.main(RMIServer.java:49)
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 12:21 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
|
|
|
Back to top |
|
|
adeel.gnome at gmail.com Guest
|
Posted: Tue Sep 02, 2008 9:20 pm Post subject: [Freeswitch-users] How to originate a session from outside |
|
|
Glad it worked for you. Actually, its not really a big deal in changing that example on the wiki. But IMO, the example should show exactly the concerned thing, just like any other example over there. In your example you got separate methods to make a call and to set the configuration, thats good. In fact, we should make the code clear, readable, and maintainable. But here its not the concern. So, I came up with the shortest code snippet, as possible. Moreover, the example is showing one more thing, if you notice, that is Java is as good as anyother language, if not superior. And we can do things in Java very precisely with a few line of codes.
P.S. Setters should not return any thing, at least in Java Naming Convention. You should rename your method "setConfig" to "getConfig", or comeup with something else.
On Tue, Sep 2, 2008 at 8:22 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Guys I made a stupid mistake again
guess what - I didn't specify the port number in the URL !!!
anyways, the code worked
the exception was because I was using an older version of XMLRPC API.
Anyways, Adeel you can modify the Java example on the wiki with this one. I think this one's better than what you already have posted there - if you don't mind that is!
I don't mean to offend you.
Thanks a lot anyways!
Regards,
Gayatri Kulkarni
-----
Whenever you find yourself on the side of the majority, it is time to pause and reflect.
From: Gayatri Kulkarni (xtpl.gayatri@gmail.com)
Sent: Tuesday, September 02, 2008 4:29 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Hey Adeel,
Remember, originate sofia/internal/1001 &bridge(sofia/internal/1003) had worked the other day?
Well, now it isn't working!
FS is still saying No_ROUTE_DESTINATION
And, it is also giving me a SAXParseException!
You want to have a look at the code?
Here it is:
/**
*
*/
package localcall;
import java.lang.String;
import java.net.*;
import org.apache.xmlrpc.XmlRpcException;
import org.apache.xmlrpc.client.XmlRpcClient;
import org.apache.xmlrpc.client.XmlRpcClientConfigImpl;
/**
* @author Gayatri Kulkarni
*
*/
public class LocalCall {
/**
*
*/
public LocalCall() {
// TODO Auto-generated constructor stub
}
public XmlRpcClientConfigImpl setConfig(){
XmlRpcClientConfigImpl conf = new XmlRpcClientConfigImpl();
String server = "http://192.168.10.36/RPC2";
String uname = "freeswitch";
String pswd = "works";
try {
URL server_url = new URL(server);
conf.setServerURL(server_url);
}
catch (MalformedURLException e){
System.out.println("Cannot generate server URL");
}
conf.setBasicPassword(pswd);
conf.setBasicUserName(uname);
return (conf);
}
public void placeCall(XmlRpcClientConfigImpl conf){
XmlRpcClient rpcClient = new XmlRpcClient();
String api = "freeswitch.api";
rpcClient.setConfig(conf);
Object[] params = new Object[]{ "originate",
"sofia/internal/1001 &bridge(sofia/internal/1002)" };
try {
rpcClient.execute(api, params );
}
catch (XmlRpcException excpn){
System.out.println("Could not execute service. \n");
excpn.printStackTrace();
}
}
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
LocalCall call = new LocalCall();
call.placeCall(call.setConfig());
}
}
I have done load mod_xml_rpc on the CLI of FS.
Thanks a lot,
Regards,
Gayatri Kulkarni
-----
Whenever you find yourself on the side of the majority, it is time to pause and reflect.
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 1:20 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Show your program. Further, try the example given in here after appropriate modification.
http://wiki.freeswitch.org/wiki/Freeswitch_XML-RPC#Java_Example
On Wed, Aug 27, 2008 at 3:56 PM, Gayatri Kulkarni <xtpl.gayatri@gmail.com (xtpl.gayatri@gmail.com)> wrote:
Quote: | Thanks a lot!
it worked - but why?
When I did the same thing through the program it gave me :
at RMIServer.main(RMIServer.java:49)
Caused by:
org.xml.sax.SAXParseException: Unknown type: string
at org.apache.xmlrpc.parser.RecursiveTypeParserImpl.startElement(Recursi
veTypeParserImpl.java:115)
at org.apache.xmlrpc.parser.XmlRpcResponseParser.startElement(XmlRpcResp
onseParser.java:126)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startEle
ment(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scan
StartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(U
nknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next
(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImp
l.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(U
nknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown So
urce)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Un
known Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.p
arse(Unknown Source)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.readResponse(XmlRpcStr
eamTransport.java:265)
at org.apache.xmlrpc.client.XmlRpcStreamTransport.sendRequest(XmlRpcStre
amTransport.java:216)
at org.apache.xmlrpc.client.XmlRpcClientWorker.execute(XmlRpcClientWorke
r.java:53)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:166)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:136)
at org.apache.xmlrpc.client.XmlRpcClient.execute(XmlRpcClient.java:125)
at RMIServer.makeACall(RMIServer.java:36)
at RMIServer.main(RMIServer.java:49)
From: Adeel Ansari (adeel.gnome@gmail.com)
Sent: Wednesday, August 27, 2008 12:21 AM
To: freeswitch-users@lists.freeswitch.org (freeswitch-users@lists.freeswitch.org)
Subject: Re: [Freeswitch-users] How to originate a session from outside
Try this,
originate sofia/internal/1001 &bridge(sofia/internal/1003)
Cheers.
|
_______________________________________________
Freeswitch-users mailing list
Freeswitch-users@lists.freeswitch.org (Freeswitch-users@lists.freeswitch.org)
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org
|
--
Best,
Adeel Ansari
http://www.linkedin.com/in/adeelansari |
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|