[Date Prev][Date Next]
Re: slow search when out-of-scope entries match (ITS#2897)
Kurt D. Zeilenga writes:
> This is an example of a search were each of the indexed components
> of the search criteria are ineffective at reducing the number of
> candidate entries. Note that the indexed components include both
> the filter and the scope.
Sure, but the _combination_ of the two would reduce the number of
candidate entires to nothing.
> There are a number of ways to address such issues:
> a) place admin limits on number of candidates,
> b) utilize "better" search criteria,
> c) utilize a "better" DIT organization,
> d) use multiple databases to localize searches/indices,
> e) tune slapd(8) (including changing various hardcoded constants)
I don't understand. Why not
f) take the intersection of
- the entries that are in scope (DN "index"),
- the entries that match the filter (attribute index)
? That would yield just the entries that actually need to be tested
with the filter. Is that impossible because of the 'ALLIDS threshold'
Pierangelo mentioned? I don't know what that is. But if so, I think
this threshold should be configurable - maybe on a per-index basis,
if there is a good performance reason not to make it too large in
> This is not viewed as a bug in the software, but an inherent aspect
> of the database backend design.
If the index isn't used, the scope should at least be used, so
that only the entries in scope are tested with the filter. Currently,
all the entires in the database are tested - in scope or not.