-
Notifications
You must be signed in to change notification settings - Fork 13
Add EscapeQueryChars util function #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@stevenferrer Hi, looks like the builds are all passing now. Request review when possible |
|
Hi @takanuva15, just to understand, the purpose of this utility function is to escape the especial characters in the query field, is that correct? |
|
Yes. To be accurate, this function is derived from the official Java client that the Solr team themselves publish on their GitHub repo here: https://github.com/apache/solr/blob/main/solr/solrj/src/java/org/apache/solr/client/solrj/util/ClientUtils.java#L205 |
Since this is considered a utility function, maybe it's good to put it in a sub-package like you suggested, maybe something like |
|
Hmm... yes we can definitely do that. My only concern is that it could make this package more confusing since developers will now have to look between 2 packages to figure out whether the function they want is in For example, in the Golang standard library, it seems like they usually just group all related stuff in a single package. For example, Along similar lines, it seems like it would match closer to the design of the Golang standard library to keep all the Solr stuff under a single package name |
I was worried that the I'll merge and publish a new release later, thanks! |
Add EscapeQueryChars util function based on solr docs. (I put it in a utils file but I can move it elsewhere if preferred)
closes #29