Skip to content

Commit 1ddcc00

Browse files
committed
Merge branch 'main' into 11654-segment-matchall
2 parents 710688a + cf3bbb8 commit 1ddcc00

File tree

332 files changed

+7912
-1580
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

332 files changed

+7912
-1580
lines changed

.github/workflows/create-documentation-issue.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
3030
- name: Create Issue From File
3131
id: create-issue
32-
uses: peter-evans/create-issue-from-file@v4
32+
uses: peter-evans/create-issue-from-file@v5
3333
with:
3434
title: Add documentation related to new feature
3535
content-filepath: ./ci/documentation/issue.md

.github/workflows/maintainer-approval.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- id: find-maintainers
12-
uses: actions/github-script@v7
12+
uses: actions/github-script@v7.0.1
1313
with:
1414
github-token: ${{ secrets.GITHUB_TOKEN }}
1515
result-encoding: string

.github/workflows/triage.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
if: github.repository == 'opensearch-project/OpenSearch'
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/github-script@v7
12+
- uses: actions/github-script@v7.0.1
1313
with:
1414
script: |
1515
const { issue, repository } = context.payload;

.github/workflows/version.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ jobs:
129129
130130
- name: Create tracking issue
131131
id: create-issue
132-
uses: actions/github-script@v6.4.0
132+
uses: actions/github-script@v7.0.1
133133
with:
134134
script: |
135135
const body = `

CHANGELOG.md

+15-4
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5959
- Add task completion count in search backpressure stats API ([#10028](https://github.com/opensearch-project/OpenSearch/pull/10028/))
6060
- Deprecate CamelCase `PathHierarchy` tokenizer name in favor to lowercase `path_hierarchy` ([#10894](https://github.com/opensearch-project/OpenSearch/pull/10894))
6161
- Switched to more reliable OpenSearch Lucene snapshot location([#11728](https://github.com/opensearch-project/OpenSearch/pull/11728))
62-
- Added support for Google Application Default Credentials in repository-gcs ([#8394](https://github.com/opensearch-project/OpenSearch/pull/8394))
6362

6463
### Deprecated
6564

@@ -86,6 +85,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
8685
- Update supported version for max_shard_size parameter in Shrink API ([#11439](https://github.com/opensearch-project/OpenSearch/pull/11439))
8786
- Fix typo in API annotation check message ([11836](https://github.com/opensearch-project/OpenSearch/pull/11836))
8887
- Update supported version for must_exist parameter in update aliases API ([#11872](https://github.com/opensearch-project/OpenSearch/pull/11872))
88+
- [Bug] Check phase name before SearchRequestOperationsListener onPhaseStart ([#12035](https://github.com/opensearch-project/OpenSearch/pull/12035))
8989

9090
### Security
9191

@@ -135,13 +135,17 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
135135
- Support index level allocation filtering for searchable snapshot index ([#11563](https://github.com/opensearch-project/OpenSearch/pull/11563))
136136
- Add `org.opensearch.rest.MethodHandlers` and `RestController#getAllHandlers` ([11876](https://github.com/opensearch-project/OpenSearch/pull/11876))
137137
- New DateTime format for RFC3339 compatible date fields ([#11465](https://github.com/opensearch-project/OpenSearch/pull/11465))
138+
- Add support for Google Application Default Credentials in repository-gcs ([#8394](https://github.com/opensearch-project/OpenSearch/pull/8394))
139+
- Remove concurrent segment search feature flag for GA launch ([#12074](https://github.com/opensearch-project/OpenSearch/pull/12074))
140+
- Enable Fuzzy codec for doc id fields using a bloom filter ([#11022](https://github.com/opensearch-project/OpenSearch/pull/11022))
141+
- [Metrics Framework] Adds support for Histogram metric ([#12062](https://github.com/opensearch-project/OpenSearch/pull/12062))
138142

139143
### Dependencies
140144
- Bumps jetty version to 9.4.52.v20230823 to fix GMS-2023-1857 ([#9822](https://github.com/opensearch-project/OpenSearch/pull/9822))
141145
- Bump Lucene from 9.7.0 to 9.8.0 ([10276](https://github.com/opensearch-project/OpenSearch/pull/10276))
142146
- Bump `commons-io:commons-io` from 2.13.0 to 2.15.1 ([#10294](https://github.com/opensearch-project/OpenSearch/pull/10294), [#11001](https://github.com/opensearch-project/OpenSearch/pull/11001), [#11002](https://github.com/opensearch-project/OpenSearch/pull/11002), [#11446](https://github.com/opensearch-project/OpenSearch/pull/11446), [#11554](https://github.com/opensearch-project/OpenSearch/pull/11554), [#11560](https://github.com/opensearch-project/OpenSearch/pull/11560), [#11796](https://github.com/opensearch-project/OpenSearch/pull/11796))
143147
- Bump `com.google.api.grpc:proto-google-common-protos` from 2.10.0 to 2.25.1 ([#10208](https://github.com/opensearch-project/OpenSearch/pull/10208), [#10298](https://github.com/opensearch-project/OpenSearch/pull/10298))
144-
- Bump `com.netflix.nebula.ospackage-base` from 11.4.0 to 11.6.0 ([#10295](https://github.com/opensearch-project/OpenSearch/pull/10295), [#11630](https://github.com/opensearch-project/OpenSearch/pull/11630))
148+
- Bump `com.netflix.nebula.ospackage-base` from 11.4.0 to 11.8.0 ([#10295](https://github.com/opensearch-project/OpenSearch/pull/10295), [#11630](https://github.com/opensearch-project/OpenSearch/pull/11630), [#12167](https://github.com/opensearch-project/OpenSearch/pull/12167))
145149
- Bump `org.apache.zookeeper:zookeeper` from 3.9.0 to 3.9.1 ([#10506](https://github.com/opensearch-project/OpenSearch/pull/10506))
146150
- Bump `de.thetaphi:forbiddenapis` from 3.5.1 to 3.6 ([#10508](https://github.com/opensearch-project/OpenSearch/pull/10508))
147151
- Bump `org.codehaus.woodstox:stax2-api` from 4.2.1 to 4.2.2 ([#10639](https://github.com/opensearch-project/OpenSearch/pull/10639))
@@ -151,7 +155,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
151155
- Bump `org.apache.logging.log4j:log4j-core` from 2.20.0 to 2.22.1 ([#10858](https://github.com/opensearch-project/OpenSearch/pull/10858), [#11000](https://github.com/opensearch-project/OpenSearch/pull/11000), [#11270](https://github.com/opensearch-project/OpenSearch/pull/11270), [#11695](https://github.com/opensearch-project/OpenSearch/pull/11695))
152156
- Bump `aws-actions/configure-aws-credentials` from 2 to 4 ([#10504](https://github.com/opensearch-project/OpenSearch/pull/10504))
153157
- Bump `stefanzweifel/git-auto-commit-action` from 4 to 5 ([#11171](https://github.com/opensearch-project/OpenSearch/pull/11171))
154-
- Bump `actions/github-script` from 6 to 7 ([#11271](https://github.com/opensearch-project/OpenSearch/pull/11271))
158+
- Bump `actions/github-script` from 6 to 7.0.1 ([#11271](https://github.com/opensearch-project/OpenSearch/pull/11271), [#12166](https://github.com/opensearch-project/OpenSearch/pull/12166))
155159
- Bump `jackson` and `jackson_databind` from 2.15.2 to 2.16.0 ([#11273](https://github.com/opensearch-project/OpenSearch/pull/11273))
156160
- Bump `netty` from 4.1.100.Final to 4.1.106.Final ([#11294](https://github.com/opensearch-project/OpenSearch/pull/11294), [#11775](https://github.com/opensearch-project/OpenSearch/pull/11775)), [#12034](https://github.com/opensearch-project/OpenSearch/pull/12034))
157161
- Bump `com.avast.gradle:gradle-docker-compose-plugin` from 0.16.12 to 0.17.6 ([#10163](https://github.com/opensearch-project/OpenSearch/pull/10163), [#11692](https://github.com/opensearch-project/OpenSearch/pull/11692))
@@ -177,12 +181,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
177181
- Bump `lycheeverse/lychee-action` from 1.8.0 to 1.9.1 ([#11795](https://github.com/opensearch-project/OpenSearch/pull/11795), [#11887](https://github.com/opensearch-project/OpenSearch/pull/11887))
178182
- Bump `Lucene` from 9.8.0 to 9.9.2 ([#11421](https://github.com/opensearch-project/OpenSearch/pull/11421)), ([#12063](https://github.com/opensearch-project/OpenSearch/pull/12063))
179183
- Bump `com.networknt:json-schema-validator` from 1.0.86 to 1.2.0 ([#11886](https://github.com/opensearch-project/OpenSearch/pull/11886), [#11963](https://github.com/opensearch-project/OpenSearch/pull/11963))
180-
- Bump `com.google.api:gax-httpjson` from 0.103.1 to 2.39.0 ([#11794](https://github.com/opensearch-project/OpenSearch/pull/11794))
184+
- Bump `com.google.api:gax-httpjson` from 0.103.1 to 2.42.0 ([#11794](https://github.com/opensearch-project/OpenSearch/pull/11794), [#12165](https://github.com/opensearch-project/OpenSearch/pull/12165))
181185
- Bump `com.google.oauth-client:google-oauth-client` from 1.34.1 to 1.35.0 ([#11960](https://github.com/opensearch-project/OpenSearch/pull/11960))
182186
- Bump `com.diffplug.spotless` from 6.23.2 to 6.25.0 ([#11962](https://github.com/opensearch-project/OpenSearch/pull/11962), [#12055](https://github.com/opensearch-project/OpenSearch/pull/12055))
183187
- Bump `com.google.cloud:google-cloud-core` from 2.5.10 to 2.30.0 ([#11961](https://github.com/opensearch-project/OpenSearch/pull/11961))
184188
- Bump `reactor-core` from 3.5.11 to 3.5.14 ([#12042](https://github.com/opensearch-project/OpenSearch/pull/12042))
185189
- Bump `com.google.http-client:google-http-client-jackson2` from 1.43.3 to 1.44.1 ([#12059](https://github.com/opensearch-project/OpenSearch/pull/12059))
190+
- Bump `peter-evans/create-issue-from-file` from 4 to 5 ([#12057](https://github.com/opensearch-project/OpenSearch/pull/12057))
191+
- Bump `org.gradle.test-retry` from 1.5.4 to 1.5.8 ([#12168](https://github.com/opensearch-project/OpenSearch/pull/12168))
186192

187193
### Changed
188194
- Mute the query profile IT with concurrent execution ([#9840](https://github.com/opensearch-project/OpenSearch/pull/9840))
@@ -206,6 +212,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
206212
- Change error message when per shard document limit is breached ([#11312](https://github.com/opensearch-project/OpenSearch/pull/11312))
207213
- Improve boolean parsing performance ([#11308](https://github.com/opensearch-project/OpenSearch/pull/11308))
208214
- Interpret byte array as primitive using VarHandles ([#11362](https://github.com/opensearch-project/OpenSearch/pull/11362))
215+
- Allow composite aggregation to run under a parent filter aggregation ([#11499](https://github.com/opensearch-project/OpenSearch/pull/11499))
209216
- Automatically add scheme to discovery.ec2.endpoint ([#11512](https://github.com/opensearch-project/OpenSearch/pull/11512))
210217
- Restore support for Java 8 for RestClient ([#11562](https://github.com/opensearch-project/OpenSearch/pull/11562))
211218
- Add deleted doc count in _cat/shards ([#11678](https://github.com/opensearch-project/OpenSearch/pull/11678))
@@ -215,6 +222,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
215222
- Ensure Jackson default maximums introduced in 2.16.0 do not conflict with OpenSearch settings ([#11890](https://github.com/opensearch-project/OpenSearch/pull/11890))
216223
- Extract cluster management for integration tests into JUnit test rule out of OpenSearchIntegTestCase ([#11877](https://github.com/opensearch-project/OpenSearch/pull/11877)), ([#12000](https://github.com/opensearch-project/OpenSearch/pull/12000))
217224
- Workaround for https://bugs.openjdk.org/browse/JDK-8323659 regression, introduced in JDK-21.0.2 ([#11968](https://github.com/opensearch-project/OpenSearch/pull/11968))
225+
- Updates IpField to be searchable when only `doc_values` are enabled ([#11508](https://github.com/opensearch-project/OpenSearch/pull/11508))
226+
- [Query Insights] Query Insights Framework which currently supports retrieving the most time-consuming queries within the last configured time window ([#11903](https://github.com/opensearch-project/OpenSearch/pull/11903))
227+
- [Query Insights] Implement Top N Queries feature to collect and gather information about high latency queries in a window ([#11904](https://github.com/opensearch-project/OpenSearch/pull/11904))
218228

219229
### Deprecated
220230

@@ -247,6 +257,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
247257
- Fix memory leak issue in ReorganizingLongHash ([#11953](https://github.com/opensearch-project/OpenSearch/issues/11953))
248258
- Prevent setting remote_snapshot store type on index creation ([#11867](https://github.com/opensearch-project/OpenSearch/pull/11867))
249259
- [BUG] Fix remote shards balancer when filtering throttled nodes ([#11724](https://github.com/opensearch-project/OpenSearch/pull/11724))
260+
- Add advance(int) for numeric values in order to allow point based optimization to kick in ([#12089](https://github.com/opensearch-project/OpenSearch/pull/12089))
250261

251262
### Security
252263

DEVELOPER_GUIDE.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ Please follow these formatting guidelines:
348348
* Wildcard imports (`import foo.bar.baz.*`) are forbidden and will cause the build to fail.
349349
* If *absolutely* necessary, you can disable formatting for regions of code with the `// tag::NAME` and `// end::NAME` directives, but note that these are intended for use in documentation, so please make it clear what you have done, and only do this where the benefit clearly outweighs the decrease in consistency.
350350
* Note that JavaDoc and block comments i.e. `/* ... */` are not formatted, but line comments i.e `// ...` are.
351-
* There is an implicit rule that negative boolean expressions should use the form `foo == false` instead of `!foo` for better readability of the code. While this isn't strictly enforced, if might get called out in PR reviews as something to change.
351+
* There is an implicit rule that negative boolean expressions should use the form `foo == false` instead of `!foo` for better readability of the code. While this isn't strictly enforced, it might get called out in PR reviews as something to change.
352352

353353
## Adding Dependencies
354354

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
/*
2+
* SPDX-License-Identifier: Apache-2.0
3+
*
4+
* The OpenSearch Contributors require contributions made to
5+
* this file be licensed under the Apache-2.0 license or a
6+
* compatible open source license.
7+
*/
8+
9+
package org.opensearch.benchmark.index.codec.fuzzy;
10+
11+
import org.apache.lucene.util.BytesRef;
12+
import org.opensearch.common.UUIDs;
13+
import org.opensearch.index.codec.fuzzy.FuzzySet;
14+
import org.opensearch.index.codec.fuzzy.FuzzySetFactory;
15+
import org.opensearch.index.codec.fuzzy.FuzzySetParameters;
16+
import org.opensearch.index.mapper.IdFieldMapper;
17+
import org.openjdk.jmh.annotations.Benchmark;
18+
import org.openjdk.jmh.annotations.BenchmarkMode;
19+
import org.openjdk.jmh.annotations.Fork;
20+
import org.openjdk.jmh.annotations.Measurement;
21+
import org.openjdk.jmh.annotations.Mode;
22+
import org.openjdk.jmh.annotations.OutputTimeUnit;
23+
import org.openjdk.jmh.annotations.Param;
24+
import org.openjdk.jmh.annotations.Scope;
25+
import org.openjdk.jmh.annotations.Setup;
26+
import org.openjdk.jmh.annotations.State;
27+
import org.openjdk.jmh.annotations.Warmup;
28+
29+
import java.io.IOException;
30+
import java.util.List;
31+
import java.util.Map;
32+
import java.util.concurrent.TimeUnit;
33+
import java.util.stream.Collectors;
34+
import java.util.stream.IntStream;
35+
36+
@Fork(3)
37+
@Warmup(iterations = 2)
38+
@Measurement(iterations = 5, time = 60, timeUnit = TimeUnit.SECONDS)
39+
@BenchmarkMode(Mode.AverageTime)
40+
@OutputTimeUnit(TimeUnit.MILLISECONDS)
41+
@State(Scope.Benchmark)
42+
public class FilterConstructionBenchmark {
43+
44+
private List<BytesRef> items;
45+
46+
@Param({ "1000000", "10000000", "50000000" })
47+
private int numIds;
48+
49+
@Param({ "0.0511", "0.1023", "0.2047" })
50+
private double fpp;
51+
52+
private FuzzySetFactory fuzzySetFactory;
53+
private String fieldName;
54+
55+
@Setup
56+
public void setupIds() {
57+
this.fieldName = IdFieldMapper.NAME;
58+
this.items = IntStream.range(0, numIds).mapToObj(i -> new BytesRef(UUIDs.base64UUID())).collect(Collectors.toList());
59+
FuzzySetParameters parameters = new FuzzySetParameters(() -> fpp);
60+
this.fuzzySetFactory = new FuzzySetFactory(Map.of(fieldName, parameters));
61+
}
62+
63+
@Benchmark
64+
public FuzzySet buildFilter() throws IOException {
65+
return fuzzySetFactory.createFuzzySet(items.size(), fieldName, () -> items.iterator());
66+
}
67+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
/*
2+
* SPDX-License-Identifier: Apache-2.0
3+
*
4+
* The OpenSearch Contributors require contributions made to
5+
* this file be licensed under the Apache-2.0 license or a
6+
* compatible open source license.
7+
*/
8+
9+
package org.opensearch.benchmark.index.codec.fuzzy;
10+
11+
import org.apache.lucene.util.BytesRef;
12+
import org.opensearch.common.UUIDs;
13+
import org.opensearch.index.codec.fuzzy.FuzzySet;
14+
import org.opensearch.index.codec.fuzzy.FuzzySetFactory;
15+
import org.opensearch.index.codec.fuzzy.FuzzySetParameters;
16+
import org.opensearch.index.mapper.IdFieldMapper;
17+
import org.openjdk.jmh.annotations.Benchmark;
18+
import org.openjdk.jmh.annotations.BenchmarkMode;
19+
import org.openjdk.jmh.annotations.Fork;
20+
import org.openjdk.jmh.annotations.Measurement;
21+
import org.openjdk.jmh.annotations.Mode;
22+
import org.openjdk.jmh.annotations.OutputTimeUnit;
23+
import org.openjdk.jmh.annotations.Param;
24+
import org.openjdk.jmh.annotations.Scope;
25+
import org.openjdk.jmh.annotations.Setup;
26+
import org.openjdk.jmh.annotations.State;
27+
import org.openjdk.jmh.annotations.Warmup;
28+
import org.openjdk.jmh.infra.Blackhole;
29+
30+
import java.io.IOException;
31+
import java.util.List;
32+
import java.util.Map;
33+
import java.util.Random;
34+
import java.util.concurrent.TimeUnit;
35+
import java.util.stream.Collectors;
36+
import java.util.stream.IntStream;
37+
38+
@Fork(3)
39+
@Warmup(iterations = 2)
40+
@Measurement(iterations = 5, time = 60, timeUnit = TimeUnit.SECONDS)
41+
@BenchmarkMode(Mode.AverageTime)
42+
@OutputTimeUnit(TimeUnit.MILLISECONDS)
43+
@State(Scope.Benchmark)
44+
public class FilterLookupBenchmark {
45+
46+
@Param({ "50000000", "1000000" })
47+
private int numItems;
48+
49+
@Param({ "1000000" })
50+
private int searchKeyCount;
51+
52+
@Param({ "0.0511", "0.1023", "0.2047" })
53+
private double fpp;
54+
55+
private FuzzySet fuzzySet;
56+
private List<BytesRef> items;
57+
private Random random = new Random();
58+
59+
@Setup
60+
public void setupFilter() throws IOException {
61+
String fieldName = IdFieldMapper.NAME;
62+
items = IntStream.range(0, numItems).mapToObj(i -> new BytesRef(UUIDs.base64UUID())).collect(Collectors.toList());
63+
FuzzySetParameters parameters = new FuzzySetParameters(() -> fpp);
64+
fuzzySet = new FuzzySetFactory(Map.of(fieldName, parameters)).createFuzzySet(numItems, fieldName, () -> items.iterator());
65+
}
66+
67+
@Benchmark
68+
public void contains_withExistingKeys(Blackhole blackhole) throws IOException {
69+
for (int i = 0; i < searchKeyCount; i++) {
70+
blackhole.consume(fuzzySet.contains(items.get(random.nextInt(items.size()))) == FuzzySet.Result.MAYBE);
71+
}
72+
}
73+
74+
@Benchmark
75+
public void contains_withRandomKeys(Blackhole blackhole) throws IOException {
76+
for (int i = 0; i < searchKeyCount; i++) {
77+
blackhole.consume(fuzzySet.contains(new BytesRef(UUIDs.base64UUID())));
78+
}
79+
}
80+
}

build.gradle

+2-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ plugins {
5555
id 'opensearch.docker-support'
5656
id 'opensearch.global-build-info'
5757
id "com.diffplug.spotless" version "6.25.0" apply false
58-
id "org.gradle.test-retry" version "1.5.4" apply false
58+
id "org.gradle.test-retry" version "1.5.8" apply false
5959
id "test-report-aggregation"
6060
id 'jacoco-report-aggregation'
6161
}
@@ -545,6 +545,7 @@ subprojects {
545545
includeClasses.add("org.opensearch.snapshots.SnapshotStatusApisIT")
546546
includeClasses.add("org.opensearch.test.rest.ClientYamlTestSuiteIT")
547547
includeClasses.add("org.opensearch.upgrade.DetectEsInstallationTaskTests")
548+
includeClasses.add("org.opensearch.cluster.MinimumClusterManagerNodesIT")
548549
}
549550
}
550551
}

distribution/packages/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ import java.util.regex.Pattern
6363
*/
6464

6565
plugins {
66-
id "com.netflix.nebula.ospackage-base" version "11.6.0"
66+
id "com.netflix.nebula.ospackage-base" version "11.8.0"
6767
}
6868

6969
void addProcessFilesTask(String type, boolean jdk) {

distribution/src/config/opensearch.yml

-6
Original file line numberDiff line numberDiff line change
@@ -117,12 +117,6 @@ ${path.logs}
117117
#opensearch.experimental.feature.extensions.enabled: false
118118
#
119119
#
120-
# Gates the concurrent segment search feature. This feature enables concurrent segment search in a separate
121-
# index searcher threadpool.
122-
#
123-
#opensearch.experimental.feature.concurrent_segment_search.enabled: false
124-
#
125-
#
126120
# Gates the optimization of datetime formatters caching along with change in default datetime formatter
127121
# Once there is no observed impact on performance, this feature flag can be removed.
128122
#

0 commit comments

Comments
 (0)