You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This one comes from an internal feature request we're working on for Rest2LDAP.
Summary
As a developer querying a deeply nested LDAP directory of users, I would like it if nested entries could be retrieved and filtered through the Rest2LDAP interface like flat collections so that I don't have to pull the full list of entries just to get information about a single entry.
Component Affected
Rest2LDAP (OpenDJ 3.5+)
Conditions of Acceptance
The Rest2LDAP module within OpenDJ is modified as follows:
A new option is added to the Rest2LDAP configuration file to allow collection sub-resources to support sub-tree flattening, such that nested LDAP entries are included as though they were all at the same flat level in the directory.
A new option is added to the Rest2LDAP configuration file to allow collection sub-resources to support an optional "base" search filter that can be used to restrict what entries get returned through the sub-resource. This search filter supplements any filters provided in the request.
Validation is added to ensure that the new sub-tree flattening option is only being used if the sub-resource is marked as read-only in the config (without this, there is no way to unambiguously map attempts to create new entries to a specific DN). Any attempt to configure a writable sub-resource with sub-tree flattening turned on must result in an error.
Sub-resources must be modified to behave as follows:
When the sub-resource has the new subtree flattening option toggled on: it should return all LDAP entries and sub-entries under the base DN that match both search filters provided on the query string as well as the search filter specified in the configuration for the sub-resource (i.e. it expands the search scope to SearchScope.SUBORDINATES).
When the sub-resource has the new subtree flattening option toggled off or has not specified whether the option is toggled on: it should return only entries that exist directly under the base DN, excluding sub-entries (i.e. the search scope is SearchScope.SINGLE_LEVEL), and then apply both search filters provided on the query string as well as the search filter specified in the configuration for the sub-resource (if any).
Workarounds / Other Approaches
Set-up a singleton resource that's mapped to a virtual static group that queries the whole sub-tree and selects the desired users from everywhere under the desired base DN. By rendering the members of the virtual static group, you can access all of the users everywhere in the subtree instead of just at the base level. Major drawback: Huge performance hit, since trying to access a single record requires pulling down the whole list of users from the server.
Don't use subtrees -- put all users under a single flat portion of the directory (not ideal for most use cases).
Don't use Rest2LDAP -- query LDAP directly from the application (not ideal because it requires all consumers to understand LDAP).
The text was updated successfully, but these errors were encountered:
Kortanul
changed the title
Feature request: Sub-tree flattening and filtering for Rest2LDAP collection sub-resources
Sub-tree flattening and filtering for Rest2LDAP collection sub-resources
Oct 29, 2017
This one comes from an internal feature request we're working on for Rest2LDAP.
Summary
As a developer querying a deeply nested LDAP directory of users, I would like it if nested entries could be retrieved and filtered through the Rest2LDAP interface like flat collections so that I don't have to pull the full list of entries just to get information about a single entry.
Component Affected
Rest2LDAP (OpenDJ 3.5+)
Conditions of Acceptance
The Rest2LDAP module within OpenDJ is modified as follows:
SearchScope.SUBORDINATES
).SearchScope.SINGLE_LEVEL
), and then apply both search filters provided on the query string as well as the search filter specified in the configuration for the sub-resource (if any).Workarounds / Other Approaches
The text was updated successfully, but these errors were encountered: