Description
Is your feature request related to a problem? Please describe.
I want to page through a large result set using continuation tokens and the azure-spring-data-cosmos library method which will accept my query with return argument. However, CosmosTemplate repository methods(paginationQuery) always issue a count query to populate the total elements in the page response, and when the query is complex and the result set is large, the count query can be very expensive.
Describe the solution you'd like
I would like to be able to use CosmosPageRequest to fetch a page of data with a continuation token without issuing a count query to populate the total elements. There is a private slice method in CosmosTemplate which is called from paginationQuery method after executing count query , would like a wrapper public method of that so that it can call directly to avoid count query .Existing private method private Slice sliceQuery(SqlQuerySpec querySpec,Pageable pageable, Sort sort,Class returnType, String containerName)
Describe alternatives you've considered
Considered extending CosmosTemplate, but too many fields and methods are defined with private access modifiers.
Additional context
Add any other context or screenshots about the feature request here.
Information Checklist
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report
- Description Added
- Expected solution specified