Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into bundle-pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
zelinh committed Dec 13, 2022
2 parents 03710cd + 1710786 commit 1f1070f
Show file tree
Hide file tree
Showing 253 changed files with 6,593 additions and 1,119 deletions.
4 changes: 1 addition & 3 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
# This should match the owning team set up in https://github.com/orgs/opensearch-project/teams
* @opensearch-project/opensearch-core @reta

* @reta @anasalkouz @andrross @reta @Bukhtawar @CEHENKLE @dblock @setiah @kartg @kotwanikunal @mch2 @nknize @owaiskazi19 @adnapibar @Rishikesh1159 @ryanbogan @saratvemulapalli @shwetathareja @dreamer-89 @tlfeng @VachaShah @xuezhou25
7 changes: 7 additions & 0 deletions .github/workflows/gradle-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,15 @@ on:
pull_request_target:
types: [opened, synchronize, reopened]

permissions:
contents: read # to fetch code (actions/checkout)

jobs:
gradle-check:
permissions:
contents: read # to fetch code (actions/checkout)
pull-requests: write # to create or update comment (peter-evans/create-or-update-comment)

runs-on: ubuntu-latest
timeout-minutes: 130
steps:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Link Checker
on:
schedule:
- cron: '0 0 * * *'
permissions:
contents: read # to fetch code (actions/checkout)
jobs:
linkchecker:
if: github.repository == 'opensearch-project/OpenSearch'
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
tags:
- '*.*.*'

permissions: {}
jobs:
build:
runs-on: ubuntu-latest
Expand Down
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,17 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [Unreleased 3.0]
### Added
- Hardened token permissions in GitHub workflows ([#4587](https://github.com/opensearch-project/OpenSearch/pull/4587))
- Support for HTTP/2 (server-side) ([#3847](https://github.com/opensearch-project/OpenSearch/pull/3847))
- Add getter for path field in NestedQueryBuilder ([#4636](https://github.com/opensearch-project/OpenSearch/pull/4636))
- Apply reproducible builds configuration for OpenSearch plugins through gradle plugin ([#4746](https://github.com/opensearch-project/OpenSearch/pull/4746))
- Add project health badges to the README.md ([#4843](https://github.com/opensearch-project/OpenSearch/pull/4843))
- [Test] Add IAE test for deprecated edgeNGram analyzer name ([#5040](https://github.com/opensearch-project/OpenSearch/pull/5040))
- Allow mmap to use new JDK-19 preview APIs in Apache Lucene 9.4+ ([#5151](https://github.com/opensearch-project/OpenSearch/pull/5151))
- Add feature flag for extensions ([#5211](https://github.com/opensearch-project/OpenSearch/pull/5211))
- Added jackson dependency to server ([#5366] (https://github.com/opensearch-project/OpenSearch/pull/5366))
- Added experimental extensions to main ([#5347](https://github.com/opensearch-project/OpenSearch/pull/5347))
- Adding support to register settings dynamically ([#5495](https://github.com/opensearch-project/OpenSearch/pull/5495))

### Dependencies
- Bumps `log4j-core` from 2.18.0 to 2.19.0
Expand Down Expand Up @@ -54,6 +58,9 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Use ReplicationFailedException instead of OpensearchException in ReplicationTarget ([#4725](https://github.com/opensearch-project/OpenSearch/pull/4725))
- Migrate client transports to Apache HttpClient / Core 5.x ([#4459](https://github.com/opensearch-project/OpenSearch/pull/4459))
- Support remote translog transfer for request level durability([#4480](https://github.com/opensearch-project/OpenSearch/pull/4480))
- Changed http code on create index API with bad input raising NotXContentException from 500 to 400 ([#4773](https://github.com/opensearch-project/OpenSearch/pull/4773))
- Change http code for DecommissioningFailedException from 500 to 400 ([#5283](https://github.com/opensearch-project/OpenSearch/pull/5283))
- Pre conditions check before updating weighted routing metadata ([#4955](https://github.com/opensearch-project/OpenSearch/pull/4955))

### Deprecated

Expand All @@ -76,11 +83,15 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
- Fix 'org.apache.hc.core5.http.ParseException: Invalid protocol version' under JDK 16+ ([#4827](https://github.com/opensearch-project/OpenSearch/pull/4827))
- Fixed compression support for h2c protocol ([#4944](https://github.com/opensearch-project/OpenSearch/pull/4944))
- Reject bulk requests with invalid actions ([#5299](https://github.com/opensearch-project/OpenSearch/issues/5299))
- Support OpenSSL Provider with default Netty allocator ([#5460](https://github.com/opensearch-project/OpenSearch/pull/5460))

### Security

## [Unreleased 2.x]
### Added
- Prevent deletion of snapshots that are backing searchable snapshot indexes ([#5069](https://github.com/opensearch-project/OpenSearch/pull/5069))
- Add max_shard_size parameter for shrink API ([#5229](https://github.com/opensearch-project/OpenSearch/pull/5229))

### Dependencies
- Bumps `bcpg-fips` from 1.0.5.1 to 1.0.7.1
- Bumps `azure-storage-blob` from 12.16.1 to 12.20.0 ([#4995](https://github.com/opensearch-project/OpenSearch/pull/4995))
Expand All @@ -92,6 +103,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
### Deprecated
### Removed
### Fixed
- Fix 1.x compatibility bug with stored Tasks ([#5412](https://github.com/opensearch-project/OpenSearch/pull/5412))
- Fix case sensitivity for wildcard queries ([#5462](https://github.com/opensearch-project/OpenSearch/pull/5462))
### Security

[Unreleased 3.0]: https://github.com/opensearch-project/OpenSearch/compare/2.4...HEAD
Expand Down
6 changes: 3 additions & 3 deletions MAINTAINERS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

| Maintainer | GitHub ID | Affiliation |
| --------------- | --------- | ----------- |
| Abbas Hussain | [abbashus](https://github.com/abbashus) | Amazon |
| Anas Alkouz | [anasalkouz](https://github.com/anasalkouz) | Amazon |
| Andrew Ross | [andrross](https://github.com/andrross)| Amazon |
| Andriy Redko | [reta](https://github.com/reta) | Aiven |
Expand All @@ -22,8 +21,8 @@
| Rishikesh Pasham | [Rishikesh1159](https://github.com/Rishikesh1159) | Amazon|
| Ryan Bogan | [ryanbogan](https://github.com/ryanbogan) | Amazon |
| Sarat Vemulapalli | [saratvemulapalli](https://github.com/saratvemulapalli) | Amazon |
| Shweta Thareja |[shwetathareja](https://github.com/shwetathareja) | Amazon |
| Suraj Singh |[dreamer-89](https://github.com/dreamer-89) | Amazon |
| Shweta Thareja | [shwetathareja](https://github.com/shwetathareja) | Amazon |
| Suraj Singh | [dreamer-89](https://github.com/dreamer-89) | Amazon |
| Tianli Feng | [tlfeng](https://github.com/tlfeng) | Amazon |
| Vacha Shah | [VachaShah](https://github.com/VachaShah) | Amazon |
| Xue Zhou | [xuezhou25](https://github.com/xuezhou25) | Amazon |
Expand All @@ -32,6 +31,7 @@

| Maintainer | GitHub ID | Affiliation |
| --------------- | --------- | ----------- |
| Abbas Hussain | [abbashus](https://github.com/abbashus) | Amazon |
| Megha Sai Kavikondala | [meghasaik](https://github.com/meghasaik) | Amazon |

[This document](https://github.com/opensearch-project/.github/blob/main/MAINTAINERS.md) explains what maintainers do in this repo, and how they should be doing it. If you're interested in contributing, see [CONTRIBUTING](CONTRIBUTING.md).
6 changes: 4 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -454,9 +454,11 @@ subprojects {
apply plugin: "org.gradle.test-retry"
tasks.withType(Test).configureEach {
retry {
if (BuildParams.isCi()) {
maxRetries = 3
maxFailures = 10
}
failOnPassedAfterRetry = false
maxRetries = 3
maxFailures = 10
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ dependencies {
api localGroovy()

api 'commons-codec:commons-codec:1.15'
api 'org.apache.commons:commons-compress:1.21'
api 'org.apache.commons:commons-compress:1.22'
api 'org.apache.ant:ant:1.10.12'
api 'com.netflix.nebula:gradle-extra-configurations-plugin:8.0.0'
api 'com.netflix.nebula:nebula-publishing-plugin:4.6.0'
Expand Down
10 changes: 5 additions & 5 deletions buildSrc/version.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ bundled_jdk = 19.0.1+10
# optional dependencies
spatial4j = 0.7
jts = 1.15.0
jackson = 2.14.0
jackson_databind = 2.14.0
jackson = 2.14.1
jackson_databind = 2.14.1
snakeyaml = 1.32
icu4j = 70.1
supercsv = 2.4.0
Expand All @@ -24,12 +24,12 @@ kotlin = 1.7.10
# when updating the JNA version, also update the version in buildSrc/build.gradle
jna = 5.5.0

netty = 4.1.84.Final
netty = 4.1.86.Final
joda = 2.10.13

# client dependencies
httpclient5 = 5.1.3
httpcore5 = 5.1.4
httpclient5 = 5.1.4
httpcore5 = 5.1.5
httpclient = 4.5.13
httpcore = 4.4.15
httpasyncclient = 4.1.5
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
import org.opensearch.common.settings.Settings;
import org.opensearch.common.xcontent.ToXContentObject;
import org.opensearch.common.xcontent.XContentBuilder;
import org.opensearch.common.unit.ByteSizeValue;

import java.io.IOException;
import java.util.Collections;
Expand All @@ -58,6 +59,7 @@ public class ResizeRequest extends TimedRequest implements Validatable, ToXConte
private final String targetIndex;
private Settings settings = Settings.EMPTY;
private Set<Alias> aliases = new HashSet<>();
private ByteSizeValue maxShardSize;

/**
* Creates a new resize request
Expand Down Expand Up @@ -155,6 +157,24 @@ public ActiveShardCount getWaitForActiveShards() {
return waitForActiveShards;
}

/**
* Sets the maximum size of a primary shard in the new shrunken index.
* This parameter can be used to calculate the lowest factor of the source index's shards number
* which satisfies the maximum shard size requirement.
*
* @param maxShardSize the maximum size of a primary shard in the new shrunken index
*/
public void setMaxShardSize(ByteSizeValue maxShardSize) {
this.maxShardSize = maxShardSize;
}

/**
* Returns the maximum size of a primary shard in the new shrunken index.
*/
public ByteSizeValue getMaxShardSize() {
return maxShardSize;
}

@Override
public XContentBuilder toXContent(XContentBuilder builder, Params params) throws IOException {
builder.startObject();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@
import org.opensearch.common.xcontent.XContentType;
import org.opensearch.test.OpenSearchTestCase;
import org.junit.Assert;
import org.opensearch.common.unit.ByteSizeValue;

import java.io.IOException;
import java.util.Arrays;
Expand Down Expand Up @@ -701,6 +702,8 @@ private void resizeTest(ResizeType resizeType, CheckedFunction<ResizeRequest, Re
RequestConvertersTests.setRandomWaitForActiveShards(resizeRequest::setWaitForActiveShards, expectedParams);
if (resizeType == ResizeType.SPLIT) {
resizeRequest.setSettings(Settings.builder().put("index.number_of_shards", 2).build());
} else if (resizeType == ResizeType.SHRINK) {
resizeRequest.setMaxShardSize(new ByteSizeValue(randomIntBetween(1, 1000)));
}

Request request = function.apply(resizeRequest);
Expand Down
1 change: 0 additions & 1 deletion client/rest/licenses/httpclient5-5.1.3.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/rest/licenses/httpclient5-5.1.4.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
208f9eed6d6ab709e2ae7a75b457ef60c0baefa5
1 change: 0 additions & 1 deletion client/rest/licenses/httpcore5-5.1.4.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/rest/licenses/httpcore5-5.1.5.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
df9da3a1fa2351c4790245400ed28d78a8ddd3fc
1 change: 0 additions & 1 deletion client/rest/licenses/httpcore5-h2-5.1.4.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/rest/licenses/httpcore5-h2-5.1.5.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
624660339afd5006d427457e6b10b10b32fd86f1
1 change: 0 additions & 1 deletion client/sniffer/licenses/httpclient5-5.1.3.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/sniffer/licenses/httpclient5-5.1.4.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
208f9eed6d6ab709e2ae7a75b457ef60c0baefa5
1 change: 0 additions & 1 deletion client/sniffer/licenses/httpcore5-5.1.4.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/sniffer/licenses/httpcore5-5.1.5.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
df9da3a1fa2351c4790245400ed28d78a8ddd3fc
1 change: 0 additions & 1 deletion client/sniffer/licenses/jackson-core-2.14.0.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions client/sniffer/licenses/jackson-core-2.14.1.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
7a07bc535ccf0b7f6929c4d0f2ab9b294ef7c4a3

This file was deleted.

This file was deleted.

4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-rc-3-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionSha256Sum=abc6de2653ec9befb00cc0d064ce1ca4e4dab2c91955e830661505189c0b2f08
distributionSha256Sum=312eb12875e1747e05c2f81a4789902d7e4ec5defbd1eefeaccc08acf096505d
Loading

0 comments on commit 1f1070f

Please sign in to comment.