directory-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Ströder <mich...@stroeder.com>
Subject Re: Getting total count of entries in a container
Date Thu, 11 Dec 2014 08:34:57 GMT
Emmanuel Lécharny wrote:
> Le 11/12/14 05:32, amit nanda a écrit :
>> I would like to  get the total count of entries under a container.
>> I application will have around 100000 entries, i can't get a direct way to
>> to this.
> 
> Plain normal.

In web2ldap I'm using various mechanisms for e.g. getting the number of
entries in a sub-tree.

No-op search control

Search and sum up server-specific operational attributes like:
- subordinateCount
- numSubordinates
- numAllSubordinates
- msDS-Approx-Immed-Subordinates

> "In the control returned to the client, the size MAY be set to the
> server's estimate of the total number of entries in the entire result
> set. Servers that cannot provide such an estimate MAY set this size to
> zero (0)."
> 
> (RFC 2696).

Interesting. I will check whether MS AD returns it.

> Side remark : it would be quite interesting to be able to provide such a
> *real* number of entries that would be returned, without actually
> returning any of those entries. The work would be done on the server,
> and returned as a control.

How about also implementing No-op search control?

In web2ldap I'm using it to display number of entries returned by a search,
number of entries affected by bulk modify/delete operations. I've extensively
tested it with OpenLDAP's slapo-noopsrch.

However there's no I-D yet.

Ciao, Michael.



Mime
View raw message