OpenSearch
OpenSearch copied to clipboard
Set analyzer to regex query string search
Description
Set default analyzer to query string search with regex
Issues Resolved
Resolves https://github.com/opensearch-project/OpenSearch/issues/3578
Check List
- [x] New functionality includes testing.
- [x] All tests pass
- [ ] New functionality has been documented.
- [ ] New functionality has javadoc added
- [x] Commits are signed per the DCO using --signoff
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check here.
Gradle Check (Jenkins) Run Completed with:
- RESULT: SUCCESS :white_check_mark:
- URL: https://build.ci.opensearch.org/job/gradle-check/866/
- CommitID: d2e6e08b1099e4bd6c5a586eb3334ef83d9e8372
Refer to the issue associated with this PR, we discussed it all there
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/940/
- CommitID: 036029a3702f8e4bd5ab446d28f41d841afbf99e
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/941/
- CommitID: 64e609866df835ec7e8794015e2b04945bf77624
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/942/
- CommitID: f5351faf71e7ac1ec14883da3a86fdea729508f7
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/943/
- CommitID: 04fb97ff2968312fd4a38027c0e70ef375f77dbe
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/944/
- CommitID: b3a4cec3131b438149582f7b3d8d56b19689f546
See below.
I am not familiar with this part of the code. Why does this work?
@dblock currently, when using regexp query, we only set the analyzer if it's forced (explicitly specify an analyzer in the search request). the reason is because of the wildcard queries ES introduced, but since wildcard queries are not being supported in OS, it's redundant now and only harm the regexp queries while searching for uppercase letters.
The change I made removes the condition to check if the force analyzer is specified and set the analyzer regardless - either the forced or by the currentFieldType
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/953/
- CommitID: 105f68d8ddc4b0ea9bf214678ebdbf5e19439684
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/1008/
- CommitID: f28e335233e622c974f4b4f70ae2d5e40d5181f2
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/1013/
- CommitID: f28e335233e622c974f4b4f70ae2d5e40d5181f2
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/1036/
- CommitID: 930cbd8997d9660e882e674420729ca0cc53b1c9
@reta @dblock I'm not sure why the gradle check is failing now.. can you take a look?
@reta @dblock I'm not sure why the gradle check is failing now.. can you take a look?
@yyyogev seems to be issue(s) with build pipeline:
/var/jenkins/workspace/gradle-check@tmp/durable-ea4df87d/script.sh: 41: docker-compose: not found
@peterzhuamazon any hints?
@reta @dblock I'm not sure why the gradle check is failing now.. can you take a look?
@yyyogev seems to be issue(s) with build pipeline:
/var/jenkins/workspace/gradle-check@tmp/durable-ea4df87d/script.sh: 41: docker-compose: not found@peterzhuamazon any hints?
Hi sorry for the late reply guys. We had a new deployment in Jenkins and missed some lines.
And we have a fix now to be reviewed.
Please be patient on this as it requires a new deployment.
Sorry and thanks. Peter
@reta @dblock I'm not sure why the gradle check is failing now.. can you take a look?
@yyyogev seems to be issue(s) with build pipeline:
/var/jenkins/workspace/gradle-check@tmp/durable-ea4df87d/script.sh: 41: docker-compose: not found@peterzhuamazon any hints?
Hi sorry for the late reply guys. We had a new deployment in Jenkins and missed some lines.
And we have a fix now to be reviewed.
Please be patient on this as it requires a new deployment.
Sorry and thanks. Peter
fixed now.
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/1050/
- CommitID: 930cbd8997d9660e882e674420729ca0cc53b1c9
@yyyogev could you please fix spotless complaints? :-) thank you.
I'm pretty sure I have already.. I'll merge from master again
Gradle Check (Jenkins) Run Completed with:
- RESULT: FAILURE :x:
- URL: https://build.ci.opensearch.org/job/gradle-check/1144/
- CommitID: 5d402871b139a9015cbbe7d0fee46dfcbffacb2a
@reta jenkins pipline still fails with the Ownership is not configured for this Run error message
@peterzhuamazon can you please validate the pipeline is working as expected?
@reta jenkins pipline still fails with the
Ownership is not configured for this Runerror message
I see
> A build operation failed.
Java heap space
> Java heap spac
... restarting
Gradle Check (Jenkins) Run Completed with:
- RESULT: SUCCESS :white_check_mark:
- URL: https://build.ci.opensearch.org/job/gradle-check/1149/
- CommitID: 5d402871b139a9015cbbe7d0fee46dfcbffacb2a
Codecov Report
Merging #3967 (5d40287) into main (740f75d) will increase coverage by
0.08%. The diff coverage is100.00%.
@@ Coverage Diff @@
## main #3967 +/- ##
============================================
+ Coverage 70.50% 70.59% +0.08%
- Complexity 56848 56906 +58
============================================
Files 4583 4583
Lines 273931 273932 +1
Branches 40158 40156 -2
============================================
+ Hits 193146 193388 +242
+ Misses 64561 64304 -257
- Partials 16224 16240 +16
| Impacted Files | Coverage Δ | |
|---|---|---|
| ...pensearch/index/search/QueryStringQueryParser.java | 70.47% <100.00%> (+0.87%) |
:arrow_up: |
| ...cluster/coordination/PendingClusterStateStats.java | 20.00% <0.00%> (-48.00%) |
:arrow_down: |
| ...adcast/BroadcastShardOperationFailedException.java | 55.55% <0.00%> (-44.45%) |
:arrow_down: |
| .../admin/cluster/reroute/ClusterRerouteResponse.java | 60.00% <0.00%> (-40.00%) |
:arrow_down: |
| ...luster/routing/allocation/RoutingExplanations.java | 62.06% <0.00%> (-37.94%) |
:arrow_down: |
| ...arch/search/aggregations/pipeline/LinearModel.java | 23.07% <0.00%> (-34.62%) |
:arrow_down: |
| ...r/src/main/java/org/opensearch/http/HttpUtils.java | 33.33% <0.00%> (-33.34%) |
:arrow_down: |
| ...min/cluster/snapshots/get/GetSnapshotsRequest.java | 52.63% <0.00%> (-31.58%) |
:arrow_down: |
| ...cluster/routing/allocation/RerouteExplanation.java | 70.00% <0.00%> (-30.00%) |
:arrow_down: |
| ...opensearch/index/reindex/BulkByScrollResponse.java | 48.38% <0.00%> (-28.23%) |
:arrow_down: |
| ... and 464 more |
Help us with your feedback. Take ten seconds to tell us how you rate us.
@yyyogev Looks like this passed the tests 🎸 @reta @dblock can you review the changes made?
@dblock - just pinging as this is 2 days since the first approval. can you please check this as well?
@reta is there anyone else who can review this one?
@reta is there anyone else who can review this one?
@nknize @andrross could you please take a look? the change seems to be reasonable
Weekly ping :/