Re: [Asterisk-java-users] Keeping AgiCahnnel alive for a long time.
Brought to you by:
srt
From: Artur T. <ar...@ca...> - 2014-01-31 16:11:08
|
The "thing" is a java application. Currently I was able to get the needed channel (it looks like SIP/192.168.220.14:52868-00000008). Can you tell how can I for example play a sound or at least NoOp to it using AMI? should I use OriginateAction to the above channel with NoOp specified as an application? I just don't see the way to send commands to channel using AMI and channel string above. On Fri, Jan 31, 2014 at 6:05 PM, Yves A. <yv...@gm...> wrote: > oops... accidentially sent before finish..... > > so... how do you control the "thing" that should be able to do the call > stuff?? some kind of webservice... anyway... > if such an action is triggered or required I´d just connect to asterisk > and fire any action with the AMI... > the only thing you have to now is the channel of the call, you want to > "manipulate".... you can do anything > (ok... depending on your asterisk version, dialplan, skill etc.). > if you don´t know the call, you can iterate through any open channel to > identify the one you need, or you > store the channel in a variable, that is set upon callstart and that you > can read from another ami connection. > you could use global or channel-variables or db-entrys for this purpose. > > right now, i am going to holidays for 10 days, so i can´t assist you the > next time... if you want further tips on this > topic after that time.... just write to the list.... > > regards, > yves > > Am 31.01.2014 17:00, schrieb Yves A.: > > Hi, > > how do you "control", > > > > > > > > > > > > > ,, > , > > > , > > > > > > > Am 30.01.2014 23:18, schrieb Artur Tamazyan: > > Let's say we receive a call and answer it. We know that it'll be a long > call and that we want to be able to do some things with it, like: join > conferences, leave that conferences, play sounds and do other stuff. So > ideally we should be able to execute any asterisk application on this > call's channel. What's the best way to do this? > > What I was trying to do is to execute AGI(..) to pass control to java. > In normal situation it'll trigger the service() method of some AgiScript > and return. But I prevent it from returning to keep the channel open for > our commands. > > Regarding AMI: as I understood we can execute apps or set contexts only > during call origination and we can't just execute smth for an already > active call. If I'm not right please give an example of how to do it. > > I hope it makes the question clearer. I can give more details if you > need. And thanks for your time. > > > On Thu, Jan 30, 2014 at 10:52 PM, Yves A. <yv...@gm...> wrote: > >> Hi, >> >> I think, I do not understand your question... could you please explain >> your scenario a bit more? >> Holding a seperate channel for controlling another channels seems a bit >> overkill... so you must have special needs >> that I do not see abd that prevent you to go the "normal" way via AMI... >> >> yves >> >> Am 30.01.2014 13:40, schrieb Artur Tamazyan: >> >> Hi guys, >> >> In our application we want to be able to send commands to a specific >> asterisk channel during a long period of time. It's a long-lasting call >> that we want to manipulate (may last for few hours). >> >> One of ways of approaching it was to make an AGI call from asterisk >> which will create an AgiScript that will hold an AgiChannel instance that >> we'll use to send our commands. >> I know that the channel is closed once AgiScript#serve() method is >> finished. As a workaround we pause the serve()'s thread to keep AgiChannel >> open as long as we need. Should we look out for any timeouts that will >> eventually close the channel automatically? Do we need to send at least >> NoOp periodiacally to keep it open? >> >> Overall this doesn't look like a good solution anyway so I want to ask >> if we have any other options to achieve our goal? >> >> I can provide more info or code if needed. >> >> >> >> ------------------------------------------------------------------------------ >> WatchGuard Dimension instantly turns raw network data into actionable >> security intelligence. It gives you real-time visual feedback on key >> security issues and trends. Skip the complicated setup - simply import >> a virtual appliance and go from zero to informed in seconds.http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk >> >> >> >> _______________________________________________ >> Asterisk-java-users mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/asterisk-java-users >> >> >> >> >> ------------------------------------------------------------------------------ >> WatchGuard Dimension instantly turns raw network data into actionable >> security intelligence. It gives you real-time visual feedback on key >> security issues and trends. Skip the complicated setup - simply import >> a virtual appliance and go from zero to informed in seconds. >> >> http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk >> _______________________________________________ >> Asterisk-java-users mailing list >> Ast...@li... >> https://lists.sourceforge.net/lists/listinfo/asterisk-java-users >> >> > > > ------------------------------------------------------------------------------ > WatchGuard Dimension instantly turns raw network data into actionable > security intelligence. It gives you real-time visual feedback on key > security issues and trends. Skip the complicated setup - simply import > a virtual appliance and go from zero to informed in seconds.http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk > > > > _______________________________________________ > Asterisk-java-users mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > > > > > ------------------------------------------------------------------------------ > WatchGuard Dimension instantly turns raw network data into actionable > security intelligence. It gives you real-time visual feedback on key > security issues and trends. Skip the complicated setup - simply import > a virtual appliance and go from zero to informed in seconds. > > http://pubads.g.doubleclick.net/gampad/clk?id=123612991&iu=/4140/ostg.clktrk > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > |