[ https://issues.apache.org/jira/browse/SOLR-599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17842429#comment-17842429 ]
Andy Webb commented on SOLR-599: -------------------------------- hey all, many thanks for your efforts here! We've just been exploring using this new client and have encountered an issue with the encoding of some characters such as curly braces, which leads to failures when we try to specify alternate query parsers in requests. As far as we can see the issue is that the new client implicitly uses {{{}SolrParams{}}}' [{{toString()}}|https://github.com/apache/solr/blob/branch_9_6/solr/solrj/src/java/org/apache/solr/common/params/SolrParams.java#L601] method rather than [{{toQueryString()}}|https://github.com/apache/solr/blob/branch_9_6/solr/solrj/src/java/org/apache/solr/common/params/SolrParams.java#L549] at [HttpJdkSolrClient.java#L263|https://github.com/apache/solr/blob/branch_9_6/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpJdkSolrClient.java#L263] and [HttpJdkSolrClient.java#L338|https://github.com/apache/solr/blob/branch_9_6/solr/solrj/src/java/org/apache/solr/client/solrj/impl/HttpJdkSolrClient.java#L338] (these are the two places we've spotted - there may be others). {{Http2SolrClient}} [uses|https://github.com/apache/solr/blob/branch_9_6/solr/solrj/src/java/org/apache/solr/client/solrj/impl/Http2SolrClient.java#L672] {{toQueryString()}} which URI-encodes curly braces as expected. Do you concur there's an issue here? thanks, Andy > Lightweight SolrJ client > ------------------------ > > Key: SOLR-599 > URL: https://issues.apache.org/jira/browse/SOLR-599 > Project: Solr > Issue Type: Improvement > Components: clients - java, SolrJ > Reporter: Shalin Shekhar Mangar > Assignee: James Dyer > Priority: Minor > Fix For: main (10.0), 9.6 > > Attachments: SOLR-599-fix-for-SolrJ-on-GAE.patch, SOLR-599.patch, > SOLR-599.patch > > Time Spent: 8h 50m > Remaining Estimate: 0h > > SolrJ provides a SolrServer implementation backed by commons-httpclient which > introduces many dependency jars (commons-codec, commons-io and > commons-logging). Apart from that SolrJ also uses StAX API for XML parsing > which introduces dependencies like stax-api, stax and stax-utils. > This enhancement will add a SolrServer implementation backed by > -java.net.HttpUrlConnection- java.net.http.HttpClient and will use > BinaryResponseParser as the default response parser. Using this basic > implementation out of the box would require no dependencies on either > commons-httpclient or StAX. The only dependency would be on solr-commons > making this a very lightweight and distribution friendly Java client for Solr. > ----- > h3. See PR [#2259|https://github.com/apache/solr/pull/2259] for details on > the actual resolution. -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org