Looking at the API I actually have something similar already written that uses a resource as a starting point and iterates down through the child resources to perform the query.
In that manner it's agnostic as to what's providing the resource, as long as we are able to obtain the children of a resource. Since it's possible for the children of a resource to be provided by multiple resource providers, handing off the queries to be handled by multiple resource providers may improve the speed of the query. Additionally, you mentioned each resource provider may optionally cache the internal results, however you would then still need to consolidate that set of data and apply ranges and limits, which I don't believe could be done effectively from within the resource provider itself. Alternatively, since I've had the same experience that Steve has had with iterative searching, an external iteration does not require that the resource provider do anything more than what it currently does which is to identify a resource and it's children. -- Jason On Thu, Jun 16, 2016, at 10:50 AM, Carsten Ziegeler wrote: > Steven Walters wrote > > I've seen this API (mentioned) before, and I don't understand why it > > has to get passed onto the ResourceProvider to handle the logic. > > It could instead be ResourceProvider agnostic, so always > > available/functioning no matter what providers are around/in use. > > Really? How? > > Carsten > > > > > Continuing to depend on ResourceProviders for such functionality > > (especially a query language this basic that could just be done > > through standard Sling resource visitation/navigation/iteration) > > doesn't seem all that beneficial, it just seems to add more complexity > > to the ResourceProviders that already have enough complexity as they > > are. > > > > > > > -- > Carsten Ziegeler > Adobe Research Switzerland > [email protected]
