Skip to content

Write the nyc_taxis longevity loops as Solr requests - #188

Draft
serhiy-bzhezytskyy wants to merge 1 commit into
apache:mainfrom
serhiy-bzhezytskyy:longevity-loops-as-solr-requests
Draft

serhiy-bzhezytskyy wants to merge 1 commit into
apache:mainfrom
serhiy-bzhezytskyy:longevity-loops-as-solr-requests

Conversation

@serhiy-bzhezytskyy

@serhiy-bzhezytskyy serhiy-bzhezytskyy commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

nyc_taxis' two longevity procedures repeat GET /_stats and POST /nyc_taxis/_refresh. Solr answers both with 404, so segment-stats-loop and refresh-loop fail on every request.

The converter now writes the cluster state of the collection, CLUSTERSTATUS, for the first, and an explicit commit for the second, under the names cluster-status-loop and commit-loop. That is the form longevity.json in solr-orbit-workloads has.

It is different work from the original. CLUSTERSTATUS returns the state of shards and replicas, without the index statistics _stats returns. A hard commit flushes to disk, where a refresh only reopens the reader. The original runs 5 clients every second for the statistics and 1 client every second for the refresh, so a Solr run is compared with an OpenSearch run that monitored much more. The same work in Solr would be the Metrics API for the statistics and a soft commit for the refresh; that is not written here, and neither is the cost of the Metrics API at 5 calls a second during indexing.

Converted from upstream, nyc_taxis' loops are cluster-status-loop (raw-request, /solr/admin/collections?action=CLUSTERSTATUS&collection=nyc_taxis&wt=json) and commit-loop (commit), the same names, types and path as in solr-orbit-workloads' longevity.json. On Solr 10.1.0, that file's indexing-search-longevity-test in test mode runs 12 tasks, both loops with an error rate of 0.

Not covered: a loop on another REST path stays as it is, and so does a loop whose clients or interval are not plain numbers (the converter reports it).

Test with:

solr-orbit convert-workload --workload-path <opensearch-benchmark-workloads>/nyc_taxis --output-path /tmp/nyc-solr
grep -n "_stats\|_refresh" /tmp/nyc-solr/CONVERTED.md
pytest tests/unit/solr -k TestRestLoops        # 8 tests; the file does not even import without the change

grep prints the two rewrites, each with what is different. A run of the converted search-longevity-test needs the auto_date_histogram operations left out first (#187).

nyc_taxis' longevity procedures repeat GET /_stats and POST /nyc_taxis/_refresh, which Solr answers with 404, so both loops failed on every request. The converter now writes the cluster state of the collection (CLUSTERSTATUS) for the statistics loop and an explicit commit for the refresh loop, the form that longevity.json in solr-orbit-workloads has, and reports what is different from the original.
@serhiy-bzhezytskyy
serhiy-bzhezytskyy force-pushed the longevity-loops-as-solr-requests branch from 15321e6 to 40f749e Compare December 3, 2026 13:33

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