Azure / Azure/azure-documentdb-java
Pagination is broken when using ORDER BY
- Dominant language
- Java
- Stars
- 51
- Forks
- 52
- PR merge metrics
- No merged PRs in 30d
Description
We are using azure-documentdb java sdk(1.16.2) for accessing cosmos db resource.
When using java sdk to access cosmos db - Pagination is working fine for all the queries except when query contains ORDER BY.
method used in sdk to get response continuation token: *feedResponse.getResponseContinuation()*
OrderByQueryExecutionComponent.getResponseHeaders() function always return null incase of query contains ORDER BY. The headers are not getting passed to the feedResponse object.
NOTE: This is after enable crosspartion query flag as true in feed options
Contributor guide
Research direction
Start by reproducing a cross-partition ORDER BY query with Azure DocumentDB Java SDK 1.16.2 and inspect OrderByQueryExecutionComponent.getResponseHeaders() alongside feedResponse.getResponseContinuation(). Done means continuation headers reach feedResponse and pagination advances correctly for ORDER BY queries, while existing non-ORDER BY pagination remains working.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- database
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100