Thread: [Asterisk-java-users] URGENT: AsteriskChannels from org.asterisk.live package don't end up in a con
Brought to you by:
srt
From: Bruno N. <bn...@gm...> - 2006-10-12 15:35:11
Attachments:
PropertyChangeEvents.txt
|
Hi Stefan and everybody, First I'd like to say thank you for your great job on org.asterisk.live. It is very straightforward and easy to use. When it will be finished it will make life much easier, absolutely. I'm testing org.asterisk.live package and I'm noticing the AsteriskChannel objects not always end up in a consistent state, even after following all the PropertyChangeEvents they fire. What showed me that was the following test. First I'll (try to) explain my test, then I'll tell what would be the expected results and then I'll show what I'm getting. ===> THE TEST: A person at extension 3025 asked the asterisk server to call the 3026 extension and then transfer the call to his extension. Simply put, the person at 3025 wants to talk to the person at 3026, but asked the asterisk server to initiate the call instead of directly dialing to 3026 by himself. To accomplish this task the asterisk server will do these steps: 1) asterisk creates a pair of "Local/3025" channels, lets say "Local/3025@foo,2" and "Local/3025@foo,1". 2) A new channel called "SIP/3025-bleh" is created and "Local/3025@foo,2" will dial to "SIP/3025-bleh". Let's assume a person on "SIP/3025-bleh" answers the phone and both channels are linked together. 3) Now a new channel called "SIP/3026-bzzz" is created and "Local/3025@foo,1" will dial it. 4) A person at "SIP/3026-bzzz" answered the phone and now a tricky process happens: 4.1) "SIP/3026-bzzz" channel is renamed to "Local/3025@foo,2<ZOMBIE>" and is hung up. 4.2) "Local/3025@foo,2" channel is renamed to "SIP/3026-bzzz", what will remain linked to "SIP/3025-bleh". 4.3) "Local/3025@foo,1" is hung up. ===> THE EXPECTED RESULT: The expected result was to find the resultant "SIP/3025-bleh" and "SIP/3026-bzzz" channels stating clearly that they are linked together, the 'callerId' should be correct on both channels and they were supposed to indicate which channel is being charged for this call. This expected result can be obtained by instantiating a new DefaultAsteriskChannel object and calling the getChannels() method. The output would be something like this: AsteriskChannel[id='1160660968.768', name='SIP/3026-bzzz', callerId='<3026>', state='UP', account='3025', dateOfCreation=Thu Oct 12 10:51:07 BRT 2006, dialedChannel=null, dialingChannel=null, linkedChannel=AsteriskChannel[id='1160660968.769',name='SIP/3025-bleh']] AsteriskChannel[id='1160660968.769', name='SIP/3025-bleh', callerId='<3025>', state='UP', account='3025',dateOfCreation=Thu Oct 12 10:54:00 BRT 2006, dialedChannel=null, dialingChannel=null, linkedChannel=AsteriskChannel[id='1160660968.768',name='SIP/3026-bzzz']] 25358555 The above AsteriskChannel objects are consistent: the 'callerId' properties are correct in both channels, also the 'account' property shows that the extension 3025 would be charged. If i would report this scenario to someone else I could picture that extension 3025 dialed to 3026. Even if it didn't do it directly (asterisk dialed for it), the idea that 3025 dialed 3026 is reasonable for this situation. ===> THE ACTUAL RESULT: If instead of running a getChannels() to obtain the resultant active AsteriskChannels I chose to follow all the PropertyChangeEvents for those four channels since they were created I would end up with the following 2 channels: AsteriskChannel[id='1160660968.768', name='SIP/3026-bzzz', callerId='<3025>', state='UP', account='null', dateOfCreation=Thu Oct 12 10:51:07 BRT 2006, dialedChannel=AsteriskChannel[id='1160660968.769', name='SIP/3025-bleh'], dialingChannel=null, linkedChannel=AsteriskChannel[id='1160660968.769',name='SIP/3025-bleh']] AsteriskChannel[id='1160660968.769', name='SIP/3025-bleh', callerId='<3025>', state='UP', account='null', dateOfCreation=Thu Oct 12 10:51:07 BRT 2006, dialedChannel=null, dialingChannel=AsteriskChannel[id='1160660968.768', name='SIP/3026-bzzz'], linkedChannel=AsteriskChannel[id='1160660968.768',name='SIP/3026-bzzz']] These channels are not consistent. By reading them you're induced to believe that 'SIP/3026-bzzz' dialed to 'SIP/3025-bleh', not the opposite. Although techically 'SIP/3026-bzzz' (former Local/3025@foo,2) indeed dialed to 'SIP/3025-bleh', it was the person at 3025 that acctually initiated the call, and the person at 3026 received the call. So the channels are not bringing useful information for this purpose. Besides that, the 'callerId' property for the 'SIP/3026-bzzz' channel is set to '3025' instead of '3026' as would be expected. The attached file is a text file showing all the PropertyChangeEvents that happen with the aforementioned channels. ===> CONCLUSION My conclusion is if I rely on PropertyChangeEvents to get my info I won't have useful information for all the possible situations. To get useful information I would need to run getChannels() from time to time. Although this would work, this is not what I need for my current project - we need real-time information on what's going on in the asterisk server, so we need to react to the PropertyChangeEvents. Guys, now tell me: Is there something I'm getting wrong from all this? Do you agree this is a problem in the org.asterisk.live package? If it's not, how should I deal with the resulting info? Also, is there any alternative strategy I could take to get the real-time information from the asterisk server without having to handle all those all-confusing, error-prone, newbies-unfriendly Events the asterisk Manager interface sends to us? Thank you very much, Bruno Negrao |
From: Stefan R. <ste...@re...> - 2006-10-14 17:23:44
Attachments:
signature.asc
|
Hi, your messages went through i dont know why they dont show up in the archives. I just didnt have the time to have a deeper look at the problem. what i get from your description is: a) the account property is not set when following events using local channels b) the callerid information is not correct in that case c) the dialed/dialingChannel are incorrect I will not promise that Asterisk-Java did everything the right way but it is very well possible that Asterisk itself did not correctly report all changes through events. Which version of Asterisk did you use for this? Do you see events that are not correctly catched by Asterisk-Java. Local channels are conceptually a very difficult thing as they act just as proxies in Asterisk and its handling is - well - sometimes confusing. If you dont really need them, don't use them ;) This would save you a lot of trouble. Besides that it would be interesting to find out what is causing the problem. And either fix Asterisk or Asterisk-Java. If you dont mind please connect to the Manager API through telnet or sniff the traffic via ngrep and compare the events to the state changes in Asterisk-Java. If you see everything is in parallel we have a problem in Asterisk, if not indicate which events were not correctly handled and i will fix it. Hope that helps a bit, Stefan Bruno Negrao wrote: > Hi Stefan and everybody, >=20 > First I'd like to say thank you for your great job on > org.asterisk.live. It is very straightforward and easy to use. When it > will be finished it will make life much easier, absolutely. >=20 > I'm testing org.asterisk.live package and I'm noticing the > AsteriskChannel objects not always end up in a consistent state, even > after following all the PropertyChangeEvents they fire. >=20 > What showed me that was the following test. First I'll (try to) > explain my test, then I'll tell what would be the expected results and > then I'll show what I'm getting. >=20 > =3D=3D=3D> THE TEST: > A person at extension 3025 asked the asterisk server to call the 3026 > extension and then transfer the call to his extension. Simply put, the > person at 3025 wants to talk to the person at 3026, but asked the > asterisk server to initiate the call instead of directly dialing to > 3026 by himself. >=20 > To accomplish this task the asterisk server will do these steps: >=20 > 1) asterisk creates a pair of "Local/3025" channels, lets say > "Local/3025@foo,2" and "Local/3025@foo,1". >=20 > 2) A new channel called "SIP/3025-bleh" is created and > "Local/3025@foo,2" will dial to "SIP/3025-bleh". Let's assume a person > on "SIP/3025-bleh" answers the phone and both channels are linked > together. >=20 > 3) Now a new channel called "SIP/3026-bzzz" is created and > "Local/3025@foo,1" will dial it. >=20 > 4) A person at "SIP/3026-bzzz" answered the phone and now a tricky > process happens: > 4.1) "SIP/3026-bzzz" channel is renamed to "Local/3025@foo,2<ZOMBIE>" > and is hung up. > 4.2) "Local/3025@foo,2" channel is renamed to "SIP/3026-bzzz", what > will remain linked to "SIP/3025-bleh". > 4.3) "Local/3025@foo,1" is hung up. >=20 > =3D=3D=3D> THE EXPECTED RESULT: > The expected result was to find the resultant "SIP/3025-bleh" and > "SIP/3026-bzzz" channels stating clearly that they are linked > together, the 'callerId' should be correct on both channels and they > were supposed to indicate which channel is being charged for this > call. >=20 > This expected result can be obtained by instantiating a new > DefaultAsteriskChannel object and calling the getChannels() method. > The output would be something like this: >=20 > AsteriskChannel[id=3D'1160660968.768', name=3D'SIP/3026-bzzz', > callerId=3D'<3026>', state=3D'UP', account=3D'3025', dateOfCreation=3DT= hu Oct > 12 10:51:07 BRT 2006, dialedChannel=3Dnull, dialingChannel=3Dnull, > linkedChannel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025-= bleh']] >=20 > AsteriskChannel[id=3D'1160660968.769', name=3D'SIP/3025-bleh', > callerId=3D'<3025>', state=3D'UP', account=3D'3025',dateOfCreation=3DTh= u Oct > 12 10:54:00 BRT 2006, dialedChannel=3Dnull, dialingChannel=3Dnull, > linkedChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'SIP/3026-= bzzz']] > 25358555 >=20 > The above AsteriskChannel objects are consistent: the 'callerId' > properties are correct in both channels, also the 'account' property > shows that the extension 3025 would be charged. If i would report this > scenario to someone else I could picture that extension 3025 dialed to > 3026. Even if it didn't do it directly (asterisk dialed for it), the > idea that 3025 dialed 3026 is reasonable for this situation. >=20 >=20 > =3D=3D=3D> THE ACTUAL RESULT: > If instead of running a getChannels() to obtain the resultant active > AsteriskChannels I chose to follow all the PropertyChangeEvents for > those four channels since they were created I would end up with the > following 2 channels: >=20 > AsteriskChannel[id=3D'1160660968.768', name=3D'SIP/3026-bzzz', > callerId=3D'<3025>', state=3D'UP', account=3D'null', dateOfCreation=3DT= hu Oct > 12 10:51:07 BRT 2006, > dialedChannel=3DAsteriskChannel[id=3D'1160660968.769', > name=3D'SIP/3025-bleh'], dialingChannel=3Dnull, > linkedChannel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025-= bleh']] >=20 > AsteriskChannel[id=3D'1160660968.769', name=3D'SIP/3025-bleh', > callerId=3D'<3025>', state=3D'UP', account=3D'null', dateOfCreation=3DT= hu Oct > 12 10:51:07 BRT 2006, dialedChannel=3Dnull, > dialingChannel=3DAsteriskChannel[id=3D'1160660968.768', > name=3D'SIP/3026-bzzz'], > linkedChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'SIP/3026-= bzzz']] >=20 > These channels are not consistent. By reading them you're induced to > believe that 'SIP/3026-bzzz' dialed to 'SIP/3025-bleh', not the > opposite. Although techically 'SIP/3026-bzzz' (former > Local/3025@foo,2) indeed dialed to 'SIP/3025-bleh', it was the person > at 3025 that acctually initiated the call, and the person at 3026 > received the call. So the channels are not bringing useful information > for this purpose. >=20 > Besides that, the 'callerId' property for the 'SIP/3026-bzzz' channel > is set to '3025' instead of '3026' as would be expected. >=20 > The attached file is a text file showing all the PropertyChangeEvents > that happen with the aforementioned channels. >=20 > =3D=3D=3D> CONCLUSION > My conclusion is if I rely on PropertyChangeEvents to get my info I > won't have useful information for all the possible situations. >=20 > To get useful information I would need to run getChannels() from time > to time. Although this would work, this is not what I need for my > current project - we need real-time information on what's going on in > the asterisk server, so we need to react to the PropertyChangeEvents. >=20 > Guys, now tell me: Is there something I'm getting wrong from all this? > Do you agree this is a problem in the org.asterisk.live package? If > it's not, how should I deal with the resulting info? >=20 > Also, is there any alternative strategy I could take to get the > real-time information from the asterisk server without having to > handle all those all-confusing, error-prone, newbies-unfriendly Events > the asterisk Manager interface sends to us? >=20 > Thank you very much, >=20 > Bruno Negrao >=20 >=20 > -----------------------------------------------------------------------= - >=20 > New Channel: AsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@f= oo,2',callerId=3D'',state=3D'RING',account=3D'null',dateOfCreation=3DThu = Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChannel=3Dnull,linke= dChannel=3Dnull] > New Channel: AsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@f= oo,1',callerId=3D'',state=3D'DOWN',account=3D'null',dateOfCreation=3DThu = Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChannel=3Dnull,linke= dChannel=3Dnull] > Property change (callerId): AsteriskChannel[id=3D'1160660968.767',name=3D= 'Local/3025@foo,1',callerId=3D'<3025>',state=3D'DOWN',account=3D'null',da= teOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingC= hannel=3Dnull,linkedChannel=3Dnull] 30971263 > Property change (callerId): AsteriskChannel[id=3D'1160660968.768',name=3D= 'Local/3025@foo,2',callerId=3D'<3025>',state=3D'RING',account=3D'null',da= teOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingC= hannel=3Dnull,linkedChannel=3Dnull] 8814217 > New Channel: AsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025-ble= h',callerId=3D'',state=3D'DOWN',account=3D'null',dateOfCreation=3DThu Oct= 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChannel=3Dnull,linkedCh= annel=3Dnull] > Property change (dialedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'RING',account=3D'n= ull',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsteri= skChannel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3D= null,linkedChannel=3Dnull] 8814217 > Property change (dialingChannel): AsteriskChannel[id=3D'1160660968.769'= ,name=3D'SIP/3025-bleh',callerId=3D'',state=3D'DOWN',account=3D'null',dat= eOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingCh= annel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2'],= linkedChannel=3Dnull] 381299 > Property change (callerId): AsteriskChannel[id=3D'1160660968.769',name=3D= 'SIP/3025-bleh',callerId=3D'<3025>',state=3D'DOWN',account=3D'null',dateO= fCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChan= nel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2'],li= nkedChannel=3Dnull] 381299 > Property change (state): AsteriskChannel[id=3D'1160660968.769',name=3D'= SIP/3025-bleh',callerId=3D'<3025>',state=3D'RINGING',account=3D'null',dat= eOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingCh= annel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2'],= linkedChannel=3Dnull] 381299 > Property change (state): AsteriskChannel[id=3D'1160660968.769',name=3D'= SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',dateOfCr= eation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChannel= =3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2'],linke= dChannel=3Dnull] 381299 > Property change (state): AsteriskChannel[id=3D'1160660968.768',name=3D'= Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'null',dateO= fCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsteriskChannel[= id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnull,linke= dChannel=3Dnull] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnu= ll,linkedChannel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025= -bleh']] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.769',= name=3D'SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2= '],linkedChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/30= 25@foo,2']] 381299 > Property change (state): AsteriskChannel[id=3D'1160660968.767',name=3D'= Local/3025@foo,1',callerId=3D'<3025>',state=3D'UP',account=3D'null',dateO= fCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialingChan= nel=3Dnull,linkedChannel=3Dnull] 30971263 > New Channel: AsteriskChannel[id=3D'1160660971.770',name=3D'SIP/3026-bzz= z',callerId=3D'',state=3D'DOWN',account=3D'null',dateOfCreation=3DThu Oct= 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingChannel=3Dnull,linkedCh= annel=3Dnull] > Property change (dialedChannel): AsteriskChannel[id=3D'1160660968.767',= name=3D'Local/3025@foo,1',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660971.770',name=3D'SIP/3026-bzzz'],dialingChannel=3Dnu= ll,linkedChannel=3Dnull] 30971263 > Property change (dialingChannel): AsteriskChannel[id=3D'1160660971.770'= ,name=3D'SIP/3026-bzzz',callerId=3D'',state=3D'DOWN',account=3D'null',dat= eOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingCh= annel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1'],= linkedChannel=3Dnull] 26680060 > Property change (callerId): AsteriskChannel[id=3D'1160660971.770',name=3D= 'SIP/3026-bzzz',callerId=3D'<3026>',state=3D'DOWN',account=3D'null',dateO= fCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingChan= nel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1'],li= nkedChannel=3Dnull] 26680060 > Property change (state): AsteriskChannel[id=3D'1160660971.770',name=3D'= SIP/3026-bzzz',callerId=3D'<3026>',state=3D'RINGING',account=3D'null',dat= eOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingCh= annel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1'],= linkedChannel=3Dnull] 26680060 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnu= ll,linkedChannel=3Dnull] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.769',= name=3D'SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2= '],linkedChannel=3Dnull] 381299 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnu= ll,linkedChannel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025= -bleh']] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.769',= name=3D'SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2= '],linkedChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/30= 25@foo,2']] 381299 > Property change (state): AsteriskChannel[id=3D'1160660971.770',name=3D'= SIP/3026-bzzz',callerId=3D'<3026>',state=3D'UP',account=3D'null',dateOfCr= eation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingChannel= =3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1'],linke= dChannel=3Dnull] 26680060 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.767',= name=3D'Local/3025@foo,1',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660971.770',name=3D'SIP/3026-bzzz'],dialingChannel=3Dnu= ll,linkedChannel=3DAsteriskChannel[id=3D'1160660971.770',name=3D'SIP/3026= -bzzz']] 30971263 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660971.770',= name=3D'SIP/3026-bzzz',callerId=3D'<3026>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1= '],linkedChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/30= 25@foo,1']] 26680060 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnu= ll,linkedChannel=3Dnull] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.769',= name=3D'SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2= '],linkedChannel=3Dnull] 381299 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.768',= name=3D'Local/3025@foo,2',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnu= ll,linkedChannel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025= -bleh']] 8814217 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.769',= name=3D'SIP/3025-bleh',callerId=3D'<3025>',state=3D'UP',account=3D'null',= dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3Dnull,dialin= gChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/3025@foo,2= '],linkedChannel=3DAsteriskChannel[id=3D'1160660968.768',name=3D'Local/30= 25@foo,2']] 381299 > Property change (name): AsteriskChannel[id=3D'1160660971.770',name=3D'S= IP/3026-bzzz<MASQ>',callerId=3D'<3026>',state=3D'UP',account=3D'null',dat= eOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dialingCh= annel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo,1'],= linkedChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@= foo,1']] 26680060 > Property change (name): AsteriskChannel[id=3D'1160660968.768',name=3D'S= IP/3026-bzzz',callerId=3D'<3025>',state=3D'UP',account=3D'null',dateOfCre= ation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsteriskChannel[id=3D= '1160660968.769',name=3D'SIP/3025-bleh'],dialingChannel=3Dnull,linkedChan= nel=3DAsteriskChannel[id=3D'1160660968.769',name=3D'SIP/3025-bleh']] 8814= 217 > Property change (name): AsteriskChannel[id=3D'1160660971.770',name=3D'L= ocal/3025@foo,2<ZOMBIE>',callerId=3D'<3026>',state=3D'UP',account=3D'null= ',dateOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull,dial= ingChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/3025@foo= ,1'],linkedChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/= 3025@foo,1']] 26680060 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660968.767',= name=3D'Local/3025@foo,1',callerId=3D'<3025>',state=3D'UP',account=3D'nul= l',dateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsterisk= Channel[id=3D'1160660971.770',name=3D'Local/3025@foo,2<ZOMBIE>'],dialingC= hannel=3Dnull,linkedChannel=3Dnull] 30971263 > Property change (linkedChannel): AsteriskChannel[id=3D'1160660971.770',= name=3D'Local/3025@foo,2<ZOMBIE>',callerId=3D'<3026>',state=3D'UP',accoun= t=3D'null',dateOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3D= null,dialingChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local= /3025@foo,1'],linkedChannel=3Dnull] 26680060 > Property change (state): AsteriskChannel[id=3D'1160660971.770',name=3D'= Local/3025@foo,2<ZOMBIE>',callerId=3D'<3026>',state=3D'HUNGUP',account=3D= 'null',dateOfCreation=3DThu Oct 12 10:51:10 BRT 2006,dialedChannel=3Dnull= ,dialingChannel=3DAsteriskChannel[id=3D'1160660968.767',name=3D'Local/302= 5@foo,1'],linkedChannel=3Dnull] 26680060 > Property change (state): AsteriskChannel[id=3D'1160660968.767',name=3D'= Local/3025@foo,1',callerId=3D'<3025>',state=3D'HUNGUP',account=3D'null',d= ateOfCreation=3DThu Oct 12 10:51:07 BRT 2006,dialedChannel=3DAsteriskChan= nel[id=3D'1160660971.770',name=3D'Local/3025@foo,2<ZOMBIE>'],dialingChann= el=3Dnull,linkedChannel=3Dnull] 30971263 >=20 >=20 > -----------------------------------------------------------------------= - >=20 > -----------------------------------------------------------------------= -- > Using Tomcat but need to do more? Need to support web services, securit= y? > Get stuff done quickly with pre-integrated technology to make your job = easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geron= imo > http://sel.as-us.falkag.net/sel?cmd=3Dlnk&kid=3D120709&bid=3D263057&dat= =3D121642 >=20 >=20 > -----------------------------------------------------------------------= - >=20 > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users --=20 reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... |
From: Bruno N. <bn...@gm...> - 2006-10-14 18:03:46
|
Hi Stefan, Thank you for answering. > Hi, > your messages went through i dont know why they dont show up in the > archives. I just didnt have the time to have a deeper look at the > problem. Ah ok, so everybody please forgive me for my re-postings. > what i get from your description is: > a) the account property is not set when following events using local > channels > b) the callerid information is not correct in that case > c) the dialed/dialingChannel are incorrect Yes, that's right. > I will not promise that Asterisk-Java did everything the right way but > it is very well possible that Asterisk itself did not correctly report > all changes through events. Which version of Asterisk did you use for > this? Version 1.2, planning to move on to 1.4. > Do you see events that are not correctly catched by Asterisk-Java. No I didn't try it untill now, good idea. Will do this on monday. > Local channels are conceptually a very difficult thing as they act just > as proxies in Asterisk and its handling is - well - sometimes confusing. It's terrible, we can admit. > If you dont really need them, don't use them ;) This would save you a > lot of trouble. Unfortunately this is not possible, I simply have to deal with them. My hope is your library magically digest all that mess for me... ;-) > Besides that it would be interesting to find out what is causing the > problem. And either fix Asterisk or Asterisk-Java. If you dont mind > please connect to the Manager API through telnet or sniff the traffic > via ngrep and compare the events to the state changes in Asterisk-Java. > If you see everything is in parallel we have a problem in Asterisk, if > not indicate which events were not correctly handled and i will fix it. Ok Stefan, I will do this. > > Hope that helps a bit, Yes, it helped because now I can show my customer that the things are not "ready to use" as they expected. We'll have to struggle a bit first. Thanks for the attention, bruno. |
From: Bruno N. <bn...@gm...> - 2006-10-19 23:58:10
|
> Besides that it would be interesting to find out what is causing the > problem. And either fix Asterisk or Asterisk-Java. If you dont mind > please connect to the Manager API through telnet or sniff the traffic > via ngrep and compare the events to the state changes in Asterisk-Java. > If you see everything is in parallel we have a problem in Asterisk, if > not indicate which events were not correctly handled and i will fix it. Stefan, I did the test using a sniffer and I concluded that asterisk is not reporting the latest events that would set the AsteriskChannels in a consistent state. Specifically, asterisk is omitting a Newcallerid event for the renamed channel that remained active, and is omitting two Newaccount (this event does not exist yet) for the two channels that remained active. The latest events sent by asterisk paralleled with the PropertyChangeEvents are described bellow. A file with the full paralleled events is attached. So what can we do now? How to report this for the asterisk staff? Would they ever listen to us? thank you, bruno. Event: Rename Privilege: call,all Oldname: SIP/3026-0a1e Newname: SIP/3026-0a1e<MASQ> Uniqueid: 1161291777.920 Server: localhost Property change (name): AsteriskChannel[id='1161291777.920', name='SIP/3026-0a1e<MASQ>',callerId='<3026>',state='UP', account='null',dateOfCreation=Thu Oct 19 18:04:40 BRST 2006, dialedChannel=null,dialingChannel=AsteriskChannel[id='1161291771.917', name='Local/3025@agente_out-6caa,1'], linkedChannel=AsteriskChannel[id='1161291771.917', name='Local/3025@agente_out-6caa,1']] 4877503 Event: Rename Privilege: call,all Oldname: Local/3025@agente_out-6caa,2 Newname: SIP/3026-0a1e Uniqueid: 1161291771.918 Server: localhost Property change (name): AsteriskChannel[id='1161291771.918',name='SIP/3026-0a1e',callerId='<3025>', state='UP',account='null',dateOfCreation=Thu Oct 19 18:04:34 BRST 2006, dialedChannel=AsteriskChannel[id='1161291771.919',name='SIP/3025-0c41'], dialingChannel=null,linkedChannel=AsteriskChannel[id='1161291771.919', name='SIP/3025-0c41']] 10605044 Event: Rename Privilege: call,all Oldname: SIP/3026-0a1e<MASQ> Newname: Local/3025@agente_out-6caa,2<ZOMBIE> Uniqueid: 1161291777.920 Server: localhost Property change (name): AsteriskChannel[id='1161291777.920',name='Local/3025@agente_out-6caa,2<ZOMBIE>', callerId='<3026>',state='UP',account='null',dateOfCreation=Thu Oct 19 18:04:40 BRST 2006, dialedChannel=null, dialingChannel=AsteriskChannel[id='1161291771.917', name='Local/3025@agente_out-6caa,1'],linkedChannel=AsteriskChannel[id='1161291771.917',name='Local/3025@agente_out-6caa,1']] 4877503 Event: Unlink Privilege: call,all Channel1: Local/3025@agente_out-6caa,1 Channel2: Local/3025@agente_out-6caa,2<ZOMBIE> Uniqueid1: 1161291771.917 Uniqueid2: 1161291777.920 CallerID1: 3025 CallerID2: 3025 Server: localhost Property change (linkedChannel): AsteriskChannel[id='1161291771.917',name='Local/3025@agente_out-6caa,1',callerId='<3025>',state='UP',account='null',dateOfCreation=Thu Oct 19 18:04:34 BRST 2006, dialedChannel=AsteriskChannel[id='1161291777.920', name='Local/3025@agente_out-6caa,2<ZOMBIE>'],dialingChannel=null,linkedChannel=null] 14440411 Property change (linkedChannel): AsteriskChannel[id='1161291777.920',name='Local/3025@agente_out-6caa, 2<ZOMBIE>', callerId='<3026>',state='UP',account='null', dateOfCreation=Thu Oct 19 18:04:40 BRST 2006, dialedChannel=null,dialingChannel=AsteriskChannel[id='1161291771.917', name='Local/3025@agente_out-6caa,1'],linkedChannel=null] 4877503 Event: Hangup Privilege: call,all Channel: Local/3025@agente_out-6caa,2<ZOMBIE> Uniqueid: 1161291777.920 Cause: 16 Cause-txt: Normal Clearing Server: localhost Property change (state): AsteriskChannel[id='1161291777.920',name='Local/3025@agente_out-6caa,2<ZOMBIE>',callerId='<3026>',state='HUNGUP',account='null',dateOfCreation=Thu Oct 19 18:04:40 BRST 2006,dialedChannel=null,dialingChannel=AsteriskChannel[id='1161291771.917',name='Local/3025@agente_out-6caa,1'],linkedChannel=null] 4877503 Event: Hangup Privilege: call,all Channel: Local/3025@agente_out-6caa,1 Uniqueid: 1161291771.917 Cause: 16 Cause-txt: Normal Clearing Server: localhost Property change (state): AsteriskChannel[id='1161291771.917',name='Local/3025@agente_out-6caa,1',callerId='<3025>',state='HUNGUP',account='null',dateOfCreation=Thu Oct 19 18:04:34 BRST 2006,dialedChannel=AsteriskChannel[id='1161291777.920',name='Local/3025@agente_out-6caa,2<ZOMBIE>'],dialingChannel=null,linkedChannel=null] 14440411 |
From: Bruno N. <bn...@gm...> - 2006-10-23 14:15:46
|
Stefan, I started discussing this topic at the Asterisk's Developers forum: http://forums.digium.com/viewtopic.php?t=10578 Regards, Bruno |
From: Stefan R. <ste...@re...> - 2006-10-23 21:18:41
Attachments:
signature.asc
|
Bruno Negrao wrote: > I started discussing this topic at the Asterisk's Developers forum: >=20 > http://forums.digium.com/viewtopic.php?t=3D10578 if you already have a patch it might be better to just open a bug on mantis and post the patch so it gets included in the next version of Asterisk. =3DStefan --=20 reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... |
From: Bruno N. <bn...@gm...> - 2006-10-24 19:09:56
|
Stefan, I can prepare a patch for asterisk and fill a bug report. And I believe this is the best solution. But I'd like to confirm with you if you agree that patching asterisk is the best solution for this problem. I'm asking your confirmation because your opinion will endorse me when I'll talk about this step with my customer. Thank you, Bruno. On 10/23/06, Stefan Reuter <ste...@re...> wrote: > > Bruno Negrao wrote: > > I started discussing this topic at the Asterisk's Developers forum: > > > > http://forums.digium.com/viewtopic.php?t=10578 > > if you already have a patch it might be better to just open a bug on > mantis and post the patch so it gets included in the next version of > Asterisk. > > =Stefan > > -- > reuter network consulting > Neusser Str. 110 > 50760 Koeln > Germany > Telefon: +49 221 1305699-0 > Telefax: +49 221 1305699-90 > E-Mail: ste...@re... > Jabber: ste...@re... > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > > > |
From: Stefan R. <ste...@re...> - 2006-10-26 08:22:40
Attachments:
signature.asc
|
Bruno Negrao wrote: > But I'd like to confirm with you if you agree that patching asterisk is= > the best solution for this problem. Yes the patch is a good thing. Remember that you must first send a disclaimer to Digium for the patch to be included in the main Asterisk distribution. Its described on mantis= =2E =3DStefan --=20 reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... |