Skip to content

[Cosmos] add additional tests and samples for paginated queries #39364

Description

Our current pagination queries don't do a very good job of showing how they can fully be used, nor how their results can be limited on a per-page basis through the use of max_item_count parameter. The closest thing we have are these tests for vector search: https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/cosmos/azure-cosmos/test/test_query_vector_similarity.py#L200 and for hybrid search: https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/cosmos/azure-cosmos/test/test_query_hybrid_search.py#L175.

We should as a minimum add similar tests in the relevant query test files showing the per-page and total results, as well as including some showing how it acts for cross-partition scenarios.

Files to enhance/ add to:

  • test_query.py
  • test_query_async.py
  • test_query_cross_partition.py
  • test_query_cross_partition_async.py
  • document_management.py
  • document_management_async.py

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

ClientThis issue points to a problem in the data-plane of the library.Cosmos

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions