[OpenSIPS-Users] drouting: + not allowed in rule prefix
Bogdan-Andrei Iancu
bogdan at voice-system.ro
Thu Jul 29 19:23:41 CEST 2010
Hi Matt,
the DR module allows only digits for prefixes as internally it builds a
decimal tree (data structures). Accepting also non-digits chars will
make the tree really huge and memory consumption will not pay off.
Usually, what I do is to replace/strip the non-digits chars before DR.
Regards,
Bogdan
Matt lehner wrote:
> Before going to drouting, I make sure all DIDs are e164 compliant. As
> such, they are prefixed with a + as is required by e164. Though, when
> I try to put a + in the prefix field of a drouting rule, it is
> rejected as an invalid prefix.
>
> Jul 25 13:31:34 [16000] ERROR:drouting:add_rule: failed to add prefix route
> Jul 25 13:31:34 [16000] ERROR:drouting:dr_load_routing_info: failed to
> add rule id 3 -> skipping
>
> Browsing through the code I see a check to make sure that all the
> characters of the prefix are digits. Is there a specific reason why
> only digits are allowed in the prefix? I can foresee a time in the
> future I may want to do prefix routing using other ascii characters.
>
> Matt
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
--
Bogdan-Andrei Iancu
OpenSIPS Bootcamp
20 - 24 September 2010, Frankfurt, Germany
www.voice-system.ro
More information about the Users
mailing list