[asterisk-bugs] [Asterisk 0011628]: fundamental (?) autoservice problem

noreply at bugs.digium.com noreply at bugs.digium.com
Wed Dec 26 11:00:32 CST 2007


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=11628 
====================================================================== 
Reported By:                dimas
Assigned To:                russell
====================================================================== 
Project:                    Asterisk
Issue ID:                   11628
Category:                   Core/Channels
Reproducibility:            always
Severity:                   major
Priority:                   normal
Status:                     assigned
Asterisk Version:           1.4.16.2 
SVN Branch (only for SVN checkouts, not tarball releases): N/A  
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             12-23-2007 10:04 CST
Last Modified:              12-26-2007 11:00 CST
====================================================================== 
Summary:                    fundamental (?) autoservice problem
Description: 
While troubleshooting an issue we are having with DTMF I discovered it is
mostly caused by the autoservice.

The problem is: 
1. ast_read does alot of emulation stuff like expanding DTMF_END into
properly separated in time DTMF_BEGIN + DTMF_END
2. ast_read is called from autoservice when running some long operations
3. autoservice queues collected frames back to the channel when stopped

This results in thse DTMF_BEGIN/DTMF_END frames getting back to next
ast_read call after autoservice has stopped. And ast_read uses these frames
as input for the emulation process again. To me this is very wrong.

Unfortunately I have no idea how to fix this at the moment. One of
approaches would be to have ast_read_raw (or something) which just returns
frame read fom the channel without any processing and queue these frames
instead. However it can cause more poblems whet it solves.

Another approach (which is a huge change) would be to have special threads
which constantly read channels doing all the processing (what __ast_read
does) and queueing result frames into special queue of the limited length
within channel. This way ast_read would only take the frame from that
queue. This way autoservice becomes unnecessary because each channel is
"autoserviced" all the time.
====================================================================== 

---------------------------------------------------------------------- 
 russell - 12-26-07 11:00  
---------------------------------------------------------------------- 
I'm not sure this is really a "bug".  It's more that it's just a bunch of
unnecessary processing.  If a BEGIN and END are queued up very quickly,
then there is code in ast_read to ensure that the digits are spaced out to
a minimum amount.  But, I'll make a change so all of this doesn't happen
... 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
12-26-07 11:00  russell        Note Added: 0075947                          
======================================================================




More information about the asterisk-bugs mailing list