[asterisk-dev] Feedback on hashtab-trunk
Niklas
niklas at tese.se
Sat Nov 17 12:19:39 CST 2007
On Mon, 12 Nov 2007 11:46:42 -0700, Steve Murphy wrote:
> Hopefully I have found them all, and you should see no more
> problems.
Well i have one issue, it picks the wrong extension. Using trunk SVN-trunk-r89346M:
extension.conf:
[general]
static=yes
writeprotect=no
[from-internal]
include=>ext_test
include=>ext_local
[ext-local]
exten=>201,1,Noop(201)
[ext_test]
exten=>20,1,Noop(20)
The CLI output when dialing 201:
lisa*CLI> dialplan reload
== Parsing '/etc/asterisk/extensions.conf': == Found
-- Registered extension context 'from-internal'
-- Including context 'ext_test' in context 'from-internal'
-- Including context 'ext_local' in context 'from-internal'
-- Registered extension context 'ext-local'
-- Added extension '201' priority 1 to ext-local
-- Registered extension context 'ext_test'
-- Added extension '20' priority 1 to ext_test
== Using TOS bits 0
== Using CoS mark 5
-- Executing [201 at from-internal:1] NoOp("SIP/2003-b7009610", "20") in new stack
-- Auto fallthrough, channel 'SIP/2003-b7009610' status is 'UNKNOWN'
lisa*CLI> dialplan show
[ Context 'ext_test' created by 'pbx_config' ]
'20' => 1. Noop(20) [pbx_config]
[ Context 'ext-local' created by 'pbx_config' ]
'201' => 1. Noop(201) [pbx_config]
[ Context 'from-internal' created by 'pbx_config' ]
Include => 'ext_test' [pbx_config]
Include => 'ext_local' [pbx_config]
[ Context 'app_queue_gosub_virtual_context' created by 'app_queue' ]
's' => 1. KeepAlive() [app_queue]
[ Context 'app_dial_gosub_virtual_context' created by 'app_dial' ]
's' => 1. KeepAlive() [app_dial]
[ Context 'parkedcalls' created by 'res_features' ]
'700' => 1. Park() [res_features]
In-mem exten Trie for Fast Extension Pattern Matching:
Explanation: Node Contents Format = <char(s) to match>:<pattern?>:<specif>:[matched extension]
Where <char(s) to match> is a set of chars, any one of which should match the current character
<pattern?>: Y if this a pattern match (eg. _XZN[5-7]), N otherwise
<specif>: an assigned 'exactness' number for this matching char. The lower the number, the more exact the match
[matched exten]: If all chars matched to this point, which extension this matches. In form: EXTEN:<exten string>
In general, you match a trie node to a string character, from left to right. All possible matching chars
are in a string vertically, separated by an unbroken string of '+' characters.
7:N:1:
+ 0:N:1:
+ + 0:N:1:EXTEN:700
-= 5 extensions (5 priorities) in 6 contexts. =-
/niklas
More information about the asterisk-dev
mailing list