Skip to content

SOLR-18093: Add top-level 'queries' support to JsonQueryRequest in SolrJ#4276

Open
ercsonusharma wants to merge 4 commits intoapache:mainfrom
ercsonusharma:feat_json_query
Open

SOLR-18093: Add top-level 'queries' support to JsonQueryRequest in SolrJ#4276
ercsonusharma wants to merge 4 commits intoapache:mainfrom
ercsonusharma:feat_json_query

Conversation

@ercsonusharma
Copy link
Copy Markdown
Contributor

@ercsonusharma ercsonusharma commented Apr 9, 2026

https://issues.apache.org/jira/browse/SOLR-18093

Description

Currently, JsonQueryRequest in SolrJ supports specifying a single query via setQuery() and other top-level parameters like limit, sort, fields etc.

However, it does not support top-level "queries" blocks, which is a good addition to fully leverage the combined query component and the Additional Queries feature in Solr’s JSON Query DSL. This limitation prevents constructing multiple queries or additional scoring/re-ranking queries in a single JSON request from the client side.

Solution

Added method to pass the required params in JsonQueryRequest. Also, enhanced the documentation.

Tests

Added Unit tests and Integration tests.

Checklist

Please review the following and check all that apply:

  • I have reviewed the guidelines for How to Contribute and my code conforms to the standards described there to the best of my ability.
  • I have created a Jira issue and added the issue ID to my pull request title.
  • I have given Solr maintainers access to contribute to my PR branch. (optional but recommended, not available for branches on forks living under an organisation)
  • I have developed this patch against the main branch.
  • I have run ./gradlew check.
  • I have added tests for my changes.
  • I have added documentation for the Reference Guide
  • I have added a changelog entry for my change

@github-actions github-actions bot added documentation Improvements or additions to documentation configs client:solrj tests labels Apr 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

client:solrj configs documentation Improvements or additions to documentation tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant