[ 
https://issues.apache.org/jira/browse/DIRSHARED-15?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12699884#action_12699884
 ] 

Stefan Seelmann commented on DIRSHARED-15:
------------------------------------------

I added two new DN parsers:

1) An initial version of a fast parser (class FastLdapDnParser) that handles 
simple DNs. More precisely is handles the following cases:
- only single RDNs are handled,
- attribute type: strings and OIDs but not the RFC1779 "oid." prefix
- values: as soon as a special character occurs ( '\' '+' '#' '"' ) an 
TooComplexExeption is thrown

2) An Antlr based DN parser that is able to handle complex DNs. Atm it contains 
some workarounds but it passes all unit tests.

The LdapDnParser class is now just a facade, that delegates parsing to the 
FastLdapDnParser and in case of an TooComplexException to the 
ComplexLdapDnParser.

Next we need to review all the tests and need to cleanup the LdapDN, Rdn and 
AttributeTypeAndValue classes. There are also some open issues (DIRSERVER-1311, 
DIRSERVER-1285, DIRSERVER-1247) with DN handling.


> Create a Fast DN parser handling simple DNs
> -------------------------------------------
>
>                 Key: DIRSHARED-15
>                 URL: https://issues.apache.org/jira/browse/DIRSHARED-15
>             Project: Directory Shared
>          Issue Type: Improvement
>    Affects Versions: 0.9.10
>            Reporter: Emmanuel Lecharny
>             Fix For: 1.0.0
>
>
> The idea is to create a parser which only handle simple DNs, containing only 
> ascii chars, no special chars, and no special cases like surrounding double 
> quotes.
> If we meet one of those special charss, we throw an exception and fall back 
> to the complex parser.
> We may gain some performance doing so.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to