Skip to content

Convert OpenSearch Benchmark's scroll into a paginated-search with a cursor - #180

Open
serhiy-bzhezytskyy wants to merge 2 commits into
apache:mainfrom
serhiy-bzhezytskyy:convert-scroll-to-paginated-search
Open

serhiy-bzhezytskyy wants to merge 2 commits into
apache:mainfrom
serhiy-bzhezytskyy:convert-scroll-to-paginated-search

Conversation

@serhiy-bzhezytskyy

Copy link
Copy Markdown
Contributor

A search with pages and results-per-page is how OpenSearch Benchmark writes a scroll. The converter kept it a search, which Solr answers with one page, so the operation paged nothing.

It now becomes a paginated-search:

  • the body's query and filters become q and fq;
  • the sort is upstream's with id asc appended, or id asc alone, because a cursor needs a sort ending with the uniqueKey and refuses _docid_;
  • no fl is set, so each page returns the stored fields.

A paginated-search now also targets the workload's collection when it names none, as a bare commit or refresh does.

For geonames the converter now writes the scroll operation of solr-orbit-workloads. On a 1,000,436-document sample it reads 25 pages of 1000 documents, as OpenSearch's scroll does. The new tests fail without the change.

…cursor

A search with pages and results-per-page is how OpenSearch Benchmark writes a scroll. The converter kept it a search, which Solr answers with one page, so the operation paged nothing. It now becomes a paginated-search: the body's query and filters become q and fq, and the sort is upstream's with id asc appended, or id asc alone, because a cursor needs a sort ending with the uniqueKey and refuses _docid_. No fl is set, so each page returns the stored fields. A paginated-search now targets the workload's collection when it names none, as a bare commit or refresh does.
# Conflicts:
#	solrorbit/conversion/workload_converter.py

This branch has not been deployed

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant